Stable IDs for requirements, scenarios and decisions

Đang mở
#2,167 0 bình luận 1 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
45/100
Loại issue
Tính năng
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
markdown, node.js, typescript
Lĩnh vực
cli, developer-experience

Hướng nghiên cứu

Read the CLI work in #1979 and the related discussions in #2056, #2113, #743, #2157, #1967, and #2033 to understand the intended behavior. Identify the validation and archive matching entry points and their tests; the issue does not name specific files. Done means IDs in bracketed headings are validated and matched before names, duplicate IDs are rejected, and specs without IDs remain unchanged.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

enhancement
The problem

Links to a requirement, scenario or decision point at its heading text, so rewording a heading breaks them, and archive refuses a renamed scenario (#1697).

Who this affects

Anyone who links tests, tasks or code to specs. In epam/ai-dial-chat, about 1 in 4 broken spec links was just a reworded heading.

What we have in mind
### Requirement: [AUTH-3] Users sign in
#### Scenario: [AUTH-3.1] Correct password

### D1
Use Redis for sessions, because restarts must not sign users out.
  • The agent writes a visible ID in square brackets at the start of the heading. There's no hidden metadata and no new command, and the CLI only reads IDs.
  • Brackets are required, so ordinary headings like SHA-256 checksum or HTTP-2 support are never mistaken for IDs.
  • Validate and archive match on the ID before the name, so renames work. Dropping an ID is still refused, and a bare prefix like NAV-5 can gain brackets.
  • Duplicate IDs are refused, which catches two parallel changes picking the same number.
  • Decisions are a ### D1 heading plus one or two sentences. There are no Rationale or Alternatives fields (the concern on #2113).
  • Specs without IDs are unchanged.

Evidence: agents kept IDs in 264 of 265 runs (details), and all 2,022 past archives in five repos rebuild byte-identical with the change.

Plan: #1979 is the CLI side; #2134 teaches the openspec-beta skills.

Not in scope: coverage reports, checking task links to removed decisions (#2056 step 2), deliberate removals (#1843), parallel-change overlap (#1669, #1387), and databases or two-way traceability.

Consolidates #2056, #2113, #743 (discussion) and #2157, plus #1967's first two directions and #2033's Direction 3.

Ngôn ngữ chính
TypeScript
Star
76k
Fork
5.2k
Merge trung bình
1 ngày 5 giờ
Pull request đã merge (30 ngày)
58

Chuẩn bị môi trường

Mở trong Codespaces

Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của Fission-AI/OpenSpec

Tất cả issue của Fission-AI/OpenSpec

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.