Loading...
Loading...
Use when external agents must construct PubFi DSL requests for OpenSearch and Postgres without server-side natural language compilation.
npx skill4agent add helixbox/pubfi-skills pubfi-dsl-clientAPI_BASEAPI_BASE=https://api-stg.pubfi.aiAPI_BASE=http://127.0.0.1:233400.0.0.0API_BASE=http://0.0.0.0:23340window.endsearch.doc_topksearch.doc_topk = 0references/dsl-schema.mdGET /v1/dsl/schemaPOST /v1/dsl/querycurl -sS "$API_BASE/v1/dsl/schema"curl -sS "$API_BASE/v1/dsl/query" \
-H 'content-type: application/json' \
-d @request.json{
"window": {"start": "2026-02-05T00:00:00Z", "end": "2026-02-06T00:00:00Z"},
"search": {"text": "liquidity stress exchange withdrawal", "doc_topk": 50},
"filters": {"tags": ["withdrawal_pause"], "entities": ["Binance"], "sources": ["coindesk"]},
"output": {
"fields": [
"document_id",
"title",
"source",
"source_published_at",
"tag_slugs",
"entity_labels",
"document_summary"
],
"aggregations": [
{
"name": "top_tags",
"aggregation": {"type": "terms", "field": "tag_slugs", "size": 50, "min_doc_count": 2}
},
{
"name": "volume_1h",
"aggregation": {"type": "date_histogram", "field": "source_published_at", "fixed_interval": "1h"}
},
{
"name": "tag_edges",
"aggregation": {"type": "cooccurrence", "field": "tag_slugs", "outer_size": 50, "inner_size": 50, "min_doc_count": 2}
}
]
}
}windowfixed_interval