Sources
langsmith
Read transcripts from LangSmith traces.
Each LangSmith root run (trace) becomes one Scout transcript. Child runs (LLM calls, tools) become events within the transcript.
Data sources:
project- Import traces from a project (default)dataset- Import examples from a dataset
async def langsmith(
project: str | None = None,
dataset: str | None = None,
from_time: datetime | None = None,
to_time: datetime | None = None,
tags: list[str] | None = None,
filter: str | None = None,
trace_filter: str | None = None,
run_type: str | None = None,
limit: int | None = None,
api_key: str | None = None,
api_url: str | None = None,
) -> AsyncIterator[Transcript]projectstr | None-
LangSmith project name. Optional for dataset, used as default data source otherwise.
datasetstr | None-
LangSmith dataset name or ID. Fetches from curated evaluation datasets instead of project traces.
from_timedatetime | None-
Only fetch traces created on or after this time
to_timedatetime | None-
Only fetch traces created before this time
tagslist[str] | None-
Filter by tags (all must match)
filterstr | None-
LangSmith filter string for run filtering. Can use filters saved from the LangSmith UI.
trace_filterstr | None-
Filter on root run attributes
run_typestr | None-
Filter by run type (llm, chain, tool, etc.)
limitint | None-
Maximum number of transcripts to fetch
api_keystr | None-
LangSmith API key (or LANGSMITH_API_KEY env var)
api_urlstr | None-
LangSmith API URL (or LANGSMITH_ENDPOINT env var)
logfire
Read transcripts from Logfire traces.
Each Logfire trace (collection of spans with same trace_id) becomes one Scout transcript. Child spans (LLM calls, tools) become events within the transcript.
async def logfire(
project: str | None = None,
from_time: datetime | None = None,
to_time: datetime | None = None,
filter: str | None = None,
trace_id: str | None = None,
limit: int | None = None,
read_token: str | None = None,
) -> AsyncIterator[Transcript]projectstr | None-
Logfire project name in format “org/project”. If not provided, queries across all accessible projects.
from_timedatetime | None-
Only fetch traces created on or after this time
to_timedatetime | None-
Only fetch traces created before this time
filterstr | None-
SQL WHERE fragment for additional filtering (e.g., “attributes->>‘gen_ai.request.model’ = ‘gpt-4o’”)
trace_idstr | None-
Fetch a specific trace by ID instead of querying
limitint | None-
Maximum number of transcripts to fetch
read_tokenstr | None-
Logfire read token (or LOGFIRE_READ_TOKEN env var). Generate from Logfire dashboard Settings > Read Tokens.