Class: LlamaCloudIndex
Constructors
new LlamaCloudIndex()
new LlamaCloudIndex(
params
):LlamaCloudIndex
Parameters
• params: CloudConstructorParams
Returns
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:24
Properties
params
params:
CloudConstructorParams
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:22
Methods
addDocuments()
addDocuments(
documents
,verbose
?):Promise
<void
>
Parameters
• documents: Document
<Metadata
>[]
• verbose?: boolean
Returns
Promise
<void
>
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:186
asQueryEngine()
asQueryEngine(
params
?):BaseQueryEngine
Parameters
• params?: object
& Omit
<RetrievalParams
, "query"
| "search_filters"
| "dense_similarity_top_k"
> & object
Returns
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:254
asRetriever()
asRetriever(
params
):BaseRetriever
Parameters
• params: CloudRetrieveParams
= {}
Returns
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:250
delete()
delete(
document
):Promise
<void
>
Parameters
• document: Document
<Metadata
>
Returns
Promise
<void
>
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:295
ensureIndex()
ensureIndex(
config
?):Promise
<void
>
Parameters
• config?
• config.embedding?: null
| AzureOpenAIEmbeddingConfig
| CohereEmbeddingConfig
| GeminiEmbeddingConfig
| HuggingFaceInferenceAPIEmbeddingConfig
| OpenAIEmbeddingConfig
| VertexAIEmbeddingConfig
| BedrockEmbeddingConfig
• config.transform?: null
| AutoTransformConfig
| AdvancedModeTransformConfig
• config.verbose?: boolean
Returns
Promise
<void
>
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:333
getPipelineId()
getPipelineId(
name
?,projectName
?,organizationId
?):Promise
<string
>
Parameters
• name?: string
• projectName?: string
• organizationId?: string
Returns
Promise
<string
>
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:139
getProjectId()
getProjectId(
projectName
?,organizationId
?):Promise
<string
>
Parameters
• projectName?: string
• organizationId?: string
Returns
Promise
<string
>
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:151
insert()
insert(
document
):Promise
<void
>
Parameters
• document: Document
<Metadata
>
Returns
Promise
<void
>
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:272
refreshDoc()
refreshDoc(
document
):Promise
<void
>
Parameters
• document: Document
<Metadata
>
Returns
Promise
<void
>
Defined in
packages/llamaindex/src/cloud/LlamaCloudIndex.ts:310
fromDocuments()
static
fromDocuments(params
,config
?):Promise
<LlamaCloudIndex
>
Adds documents to the given index parameters. If the index does not exist, it will be created.
Parameters
• params: object
& object
& ClientParams
An object containing the following properties:
- documents: An array of Document objects to be added to the index.
- verbose: Optional boolean to enable verbose logging.
- Additional properties from CloudConstructorParams.
• config?
• config.embedding?: undefined
| null
| AzureOpenAIEmbeddingConfig
| CohereEmbeddingConfig
| GeminiEmbeddingConfig
| HuggingFaceInferenceAPIEmbeddingConfig
| OpenAIEmbeddingConfig
| VertexAIEmbeddingConfig
| BedrockEmbeddingConfig
• config.transform?: undefined
| null
| AutoTransformConfig
| AdvancedModeTransformConfig
Returns
Promise
<LlamaCloudIndex
>
A Promise that resolves to a new LlamaCloudIndex instance.