/langfuse/.
For credential setup, see Langfuse Setup.
Config
| Config field | Required | Default | Description |
|---|---|---|---|
public_key | yes | Langfuse project public key | |
secret_key | yes | Langfuse project secret key | |
host | no | https://cloud.langfuse.com | Langfuse API host URL |
default_trace_limit | no | 100 | Default trace/observation cap for listings |
default_search_limit | no | 50 | Default result cap for search at directory scope |
Filesystem Layout
Traces
/langfuse/traces/ lists recent traces (capped at default_trace_limit).
Each trace is a .json file containing the full trace object with nested
observations (spans, generations, events).
Sessions
/langfuse/sessions/ groups traces by session ID. Each session directory
contains trace .json files belonging to that session.
Prompts
/langfuse/prompts/ lists prompt names as directories. Each prompt directory
contains version files (1.json, 2.json, etc.) with the prompt content
and metadata.
Datasets
/langfuse/datasets/ lists dataset names as directories. Each contains
items.jsonl (dataset items) and runs/ with run results.
Smart Commands
grep at different scopes
- traces/: filters by trace name, user ID, or tags
- sessions/: filters by session listing
- prompts/: filters by prompt name
head / tail
head and tail on traces/ use Langfuse API pagination with sort order
instead of downloading all traces:
Limits
| Command | Limit behavior |
|---|---|
ls traces/ | Returns up to default_trace_limit traces |
cat traces/<id>.json | Full trace (single doc, no limit needed) |
grep (directory level) | Server-side filter, capped at default_search_limit |
wc -l traces/ | Not supported (Langfuse has no count endpoint) |
Cache
The Langfuse resource usesIndexCacheStore (same as other resources).
Index entries store trace IDs, session IDs, and prompt names.
Example
Shell Commands
| Command | Notes |
|---|---|
ls | List traces, sessions, prompts, datasets |
cat | Read trace JSON, prompt version, dataset items |
head / tail | Paginated trace listing with sort |
grep / rg | Smart: uses Langfuse filter API at directory scope |
jq | Query JSON trace/prompt data |
stat | Metadata (trace count, prompt versions, dataset items) |
find | Search across resources with -name |
tree | Directory tree view |