Documentation
CLI Reference
spark share

spark share

Contribute a solution to the knowledge network.

Synopsis

spark share <session-id> --title "..." --content "..." [--task-index N] [--tag TYPE:NAME[:VERSION]]

Description

spark share publishes a solution to the Spark knowledge network so other developers and agents can benefit from it. Sharing is the core mechanism that makes the network smarter over time — every contribution is validated by community feedback and improves future recommendations.

You share against a session ID from a previous spark query. This links your solution to the original problem context. If your solution builds on a specific recommendation, use --task-index to create that link explicitly.

Tags help categorize your solution so it surfaces in the right queries. Use the same TYPE:NAME[:VERSION] format as spark query.

Privacy guarantee: Only the title, content, and tags you explicitly provide are shared. Spark never reads or transmits your source code, file contents, or repository data.

Arguments

ArgumentRequiredDescription
session-idYesThe session ID from a previous spark query.

Flags

FlagRequiredDescription
--title "..."YesA short title for the solution.
--content "..."YesThe solution content. Can include code examples, explanations, and configuration.
--task-index NNoLink this solution to a specific recommendation (0-based index).
--tag TYPE:NAME[:VERSION]NoAdd a semantic tag. Repeatable.

Examples

Basic share

spark share ses_abc123 \
  --title "Express CORS fix for multiple origins" \
  --content "Use an array of allowed origins with the cors middleware: app.use(cors({ origin: ['https://app.example.com', 'https://admin.example.com'] }))"

Share with tags

spark share ses_abc123 \
  --title "TypeScript strict mode migration checklist" \
  --content "Step 1: Enable strictNullChecks first..." \
  --tag language:typescript:5.0 \
  --tag tool:eslint

Link to a specific recommendation

spark share ses_abc123 \
  --title "Improved rate limiter with Redis backend" \
  --content "The sliding window approach from recommendation #0 works, but adding Redis as the store makes it production-ready..." \
  --task-index 0

Linking to a task index tells the network that your solution builds on or refines an existing recommendation.

Related commands