LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • Client
  • AsyncClient
  • Run Helpers
  • Run Trees
  • Evaluation
  • Schemas
  • Utilities
  • Wrappers
  • Anonymizer
  • Testing
  • Expect API
  • Middleware
  • Pytest Plugin
  • Deployment SDK
⌘I

LangChain Assistant

Ask a question to get started

Enter to send•Shift+Enter new line

Menu

OverviewClientAsyncClientRun HelpersRun TreesEvaluationSchemasUtilitiesWrappersAnonymizerTestingExpect APIMiddlewarePytest PluginDeployment SDK
Language
Theme
PythonlangsmithclientClientlist_examples
Method●Since v0.0

list_examples

Copy
list_examples( self, dataset_id: Optional[ID_TYPE] = None, dataset_name: Optional
View source on GitHub
[
str
]
=
None
,
example_ids
:
Optional
[
Sequence
[
ID_TYPE
]
]
=
None
,
as_of
:
Optional
[
Union
[
datetime
.
datetime
,
str
]
]
=
None
,
splits
:
Optional
[
Sequence
[
str
]
]
=
None
,
inline_s3_urls
:
bool
=
True
,
*
,
offset
:
int
=
0
,
limit
:
Optional
[
int
]
=
None
,
metadata
:
Optional
[
dict
]
=
None
,
filter
:
Optional
[
str
]
=
None
,
include_attachments
:
bool
=
False
,
**
kwargs
:
Any
=
{
}
)
->
Iterator
[
ls_schemas
.
Example
]

Parameters

NameTypeDescription
dataset_idOptional[Union[UUID, str]]
Default:None

The ID of the dataset to filter by.

dataset_nameOptional[str]
Default:None
example_idsOptional[Sequence[Union[UUID, str]]
Default:None
as_ofOptional[Union[datetime.datetime, str]]
Default:None
splitsOptional[Sequence[str]]
Default:None
inline_s3_urlsbool, default=True
Default:True
offsetint, default=0
Default:0
limitOptional[int]
Default:None
metadataOptional[dict]
Default:None
filterOptional[str]
Default:None
include_attachmentsbool, default=False
Default:False
**kwargsAny
Default:{}

Retrieve the example rows of the specified dataset.

The name of the dataset to filter by.

The IDs of the examples to filter by.

The dataset version tag OR timestamp to retrieve the examples as of. Response examples will only be those that were present at the time of the tagged (or timestamped) version.

A list of dataset splits, which are divisions of your dataset such as 'train', 'test', or 'validation'. Returns examples only from the specified splits.

Whether to inline S3 URLs.

The offset to start from. Defaults to 0.

The maximum number of examples to return.

A dictionary of metadata to filter by.

A structured filter string to apply to the examples.

Whether to include the attachments in the response.

Additional keyword arguments are ignored.