Skip to content

TeichAI/datacli

Repository files navigation

DataCLI

DataCLI generates JSONL chat datasets and agent traces from structured JSONL prompts. It includes a command-line interface, a reusable TypeScript SDK, and a core execution runtime.

Requirements

  • Node.js 22.19.0 or newer
  • An API key for generate, or provider credentials supported by Pi for trace

Install

npm install --global @teichai/datacli

Quick start

Create prompts.jsonl:

{"prompt":"Explain the CAP theorem in simple terms.","metadata":{"topic":"distributed-systems"}}
{"prompt":["Write a JavaScript function that reverses a string.","Now add input validation."],"metadata":{"topic":"javascript"}}

Set an OpenRouter API key and generate a dataset:

export OPENROUTER_API_KEY="your-key"
datacli generate \
  --model openai/gpt-4o-mini \
  --prompts prompts.jsonl \
  --out dataset.jsonl

Each input record produces one validated output record. See Getting started for the complete walkthrough.

Documentation

Development

npm install
npm test

See Development for workspace structure, build commands, and testing guidance.

License

Apache License 2.0

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages