allium skills: document invariant+@guidance pattern for complex semantics

オープン 初心者向け
#8 コメント 1 件 リアクション 1 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
65/100
issue の種類
ドキュメント
明瞭さ
おおむね明確
活発さ
静か
領域
documentation

調査の方向性

まず既存の allium skills、特に allium:tend と、wemble issue #109 のソースコンテキストを確認します。collection の処理と複数フェーズの並行性を含め、formal rules を使うべき場合と invariant に @guidance を加えるパターンを使うべき場合を文書化します。パターンとその判断基準が spec authors にとって明確になれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Context

When Allium behaviors are too complex to express as trigger/ensures rules (e.g., concurrent iteration, parallel merge, heterogeneous collection processing), there's a useful workaround pattern that isn't documented in the allium skills.

Pattern

Use invariant Name { true } with an @guidance block for prose:

invariant ParallelMerge { true }
@guidance """
All parallel branches execute concurrently.
Results are merged into the parent entity when all branches complete.
"""

The checker accepts this; the meaningful content lives in the guidance annotation.

Request

Document this pattern in the allium skills (likely allium:tend or a new "Spec Authoring Patterns" section) explaining:

  • When to use formal rules vs invariant+@guidance
  • Reserve formal rules for entity state transitions and attribute causality
  • Use invariants+@guidance for behaviors involving collection processing or multi-phase concurrency

Source

Discovered during wemble issue #109 — parallel/iterate/cond semantics couldn't be expressed cleanly with Allium rule syntax.

主要言語
JavaScript
スター
10
フォーク
6
平均マージ
9分
マージ済み PR(30日)
1

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

似ている issue

JavaScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。