Skip to main content
All trace commands live under the trace group (alias: t).

trace init

Scan your codebase for LLM usage and generate a valiqor_init.py initialization file with workflow suggestions.

What It Does

  1. Runs a context scanner for feature detection
  2. Scans your codebase for LLM usage (detects providers and entry points)
  3. Generates valiqor_init.py with recommended workflow decorators
  4. Creates the trace output directory
  5. Updates .gitignore to exclude trace files

Example

If no .valiqorrc exists, the CLI auto-configures the project before scanning.

trace apply

Apply @trace_workflow decorators to your Python files based on scan suggestions.

Behavior

  • By default, applies decorators only to recommended entry points.
  • --all includes alternative entry points as well.
  • Creates backups of modified files before applying changes.
  • If valiqor_init.py is stale (scan ID mismatch), the CLI re-scans automatically before applying.

Example


trace uninstrument

Remove auto-applied Valiqor instrumentation (decorators and imports) from Python files.

Example

Excludes dotfiles and valiqor_init.py by default.

trace refresh

Re-scan the codebase and regenerate valiqor_init.py with updated suggestions.

Example

Runs the context scanner and LLM detection again, then prompts before overwriting the existing valiqor_init.py.