Class: InMemoryDocstore
docstore.InMemoryDocstore
Hierarchy
↳
InMemoryDocstore
Constructors
constructor
• new InMemoryDocstore(docs?
)
Parameters
Name | Type |
---|---|
docs? | Map <string , Document <Record <string , any >>> |
Overrides
Defined in
langchain/src/docstore/in_memory.ts:7
Properties
_docs
• _docs: Map
<string
, Document
<Record
<string
, any
>>>
Defined in
langchain/src/docstore/in_memory.ts:5
Accessors
count
• get
count(): number
Method for getting count of documents in _docs
Returns
number
Defined in
langchain/src/docstore/in_memory.ts:13
Methods
add
▸ add(texts
): void
Parameters
Name | Type |
---|---|
texts | Record <string , Document <Record <string , any >>> |
Returns
void
Overrides
Defined in
langchain/src/docstore/in_memory.ts:21
search
▸ search(search
): string
| Document
<Record
<string
, any
>>
Parameters
Name | Type |
---|---|
search | string |
Returns
string
| Document
<Record
<string
, any
>>
Overrides
Defined in
langchain/src/docstore/in_memory.ts:17