OpenSkopos

v0.3.4
io.github.openskopos/openskopos Checked 5 hours ago Published 10 hours ago

Check, fix, convert, compare and merge OpenSkopos decision documents.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

check Check a document

Check an OpenSkopos document against the JSON Schema and the rules of the specification. Gives each problem with its JSON Pointer path, a hint for people, and whether the fix tool can fix it.

ParameterTypeDescription
document *stringThe whole document: OpenSkopos JSON, YAML or Markdown text, as in the file.
filenamestringThe name of the file, for example INTENT.md or app.skopos.yaml. Sets the format, and the kind of a Markdown file without one.
formatstringThe format of the text. Default: from `filename`, else detected (JSON starts with '{'; Markdown has a '# ' title line).

fix Fix a document

Apply every fix that needs no choice from a person (for example ID counters), then check again. Gives the fixed document, the fixes applied and the problems that are left.

ParameterTypeDescription
document *stringThe whole document: OpenSkopos JSON, YAML or Markdown text, as in the file.
filenamestringThe name of the file, for example INTENT.md or app.skopos.yaml. Sets the format, and the kind of a Markdown file without one.
formatstringThe format of the text. Default: from `filename`, else detected (JSON starts with '{'; Markdown has a '# ' title line).
output_formatstringThe format of the document in the result. Default: the format of the input.

convert Convert or format a document

Write a document as JSON, YAML or Markdown in the canonical key order and layout. Use the same format to format a file (as `skopos fmt` does). Markdown is the readable agent file (specification section 10).

ParameterTypeDescription
document *stringThe whole document: OpenSkopos JSON, YAML or Markdown text, as in the file.
to *stringThe format to write.
filenamestringThe name of the file, for example INTENT.md or app.skopos.yaml. Sets the format, and the kind of a Markdown file without one.
formatstringThe format of the text. Default: from `filename`, else detected (JSON starts with '{'; Markdown has a '# ' title line).

assign_ids Assign item IDs

Give an ID to each item that has none, and update id_counters. Gives the new IDs and the document.

ParameterTypeDescription
document *stringThe whole document: OpenSkopos JSON, YAML or Markdown text, as in the file.
filenamestringThe name of the file, for example INTENT.md or app.skopos.yaml. Sets the format, and the kind of a Markdown file without one.
formatstringThe format of the text. Default: from `filename`, else detected (JSON starts with '{'; Markdown has a '# ' title line).
output_formatstringThe format of the document in the result. Default: the format of the input.

render Render a document

Show a document as plain text (default) or as one self-contained HTML page. With `previous`, the view marks what was added, changed and removed since that version.

ParameterTypeDescription
document *stringThe whole document: OpenSkopos JSON, YAML or Markdown text, as in the file.
asstringDefault: text.
previousstringAn earlier version of the same artifact (optional): OpenSkopos JSON, YAML or Markdown text, as in the file.
widthintegerText only: the line width. Default: 100.

diff Compare two versions

The items that were added, changed, dropped and superseded between two documents, as `skopos diff` gives them.

ParameterTypeDescription
new *stringThe newer document: OpenSkopos JSON, YAML or Markdown text, as in the file.
old *stringThe older document: OpenSkopos JSON, YAML or Markdown text, as in the file.

history History of documents

The history of several documents from one or more artifacts, in any order: each version and what changed, and the links between artifacts.

ParameterTypeDescription
documents *arrayThe documents, in any order.
sinceintegerShow only the versions after this version number.

trace Trace one item

The life of one item across versions and artifacts, from a reference string such as 'FR3' or 'pa_xxxxxxxxxxxxxxxx#FR3'.

ParameterTypeDescription
documents *array
reference *stringThe item, for example FR3 or <artifact id>#FR3.

merge Merge two documents

Merge another document into main. Gives the next version of main as a draft, with the items of each conflict as proposed items. Resolve each conflict with the resolve tool, which accepts one side of it. Give `base`, the common earlier version, for a three-way merge.

ParameterTypeDescription
main *stringThe main document: OpenSkopos JSON, YAML or Markdown text, as in the file.
other *stringThe document to merge into main: OpenSkopos JSON, YAML or Markdown text, as in the file.
basestringThe common earlier version (optional): OpenSkopos JSON, YAML or Markdown text, as in the file.
output_formatstringThe format of the document in the result. Default: the format of the input.
pairsarrayPairs that people confirmed, as [main ID, other ID]. No other items pair.

conflicts Open conflicts

The open conflicts of a merged document: each pair of items where a person must choose one.

ParameterTypeDescription
document *stringThe whole document: OpenSkopos JSON, YAML or Markdown text, as in the file.

resolve Resolve a conflict

Accept the item with this ID and reject the other item of its open conflict. In a conflict with several items on a side, accept every item on the side of this item and reject the others. Gives the new document.

ParameterTypeDescription
document *stringThe whole document: OpenSkopos JSON, YAML or Markdown text, as in the file.
id *stringThe ID of the item to accept.
output_formatstringThe format of the document in the result. Default: the format of the input.

export Export to a spec tool

Export a document to the files of OpenSpec, Kiro or GitHub Spec Kit. Gives each file with its path, and the items that the tool has no place for.

ParameterTypeDescription
document *stringThe whole document: OpenSkopos JSON, YAML or Markdown text, as in the file.
tool *string
namestringThe name of the change or feature. Default: from the title.
numberintegerSpec Kit only: the feature number. Default: 1.

spec Read the specification

The OpenSkopos 0.3 specification (Markdown), one section of it, its JSON Schema, or the names of its rules. Read section 4 for the item types and section 10 for the Markdown format.

ParameterTypeDescription
sectionintegerOne numbered section. Default: the contents.
whatstringDefault: spec.