Skip to content

feat(ogar-vocab): Priority — 7th promoted concept (project_work_item.priority canonical target)#65

Merged
AdaWorldAPI merged 1 commit into
mainfrom
claude/ogar-vocab-priority
Jun 19, 2026
Merged

feat(ogar-vocab): Priority — 7th promoted concept (project_work_item.priority canonical target)#65
AdaWorldAPI merged 1 commit into
mainfrom
claude/ogar-vocab-priority

Conversation

@AdaWorldAPI

Copy link
Copy Markdown
Owner

7th promoted concept — Priority

Continues the OP↔Redmine ladder closing forward references on project_work_item family edges. Both curators use IssuePriority < Enumeration with the universal name / position / is_default triple and the back-reference has_many :issues / :work_packages to ProjectWorkItem.

What

  • ogar_vocab::priority() canonical class — HasMany work_items → ProjectWorkItem + typed attrs (name string, position integer, is_default boolean) + Language::Unknown.
  • CODEBOOK entry: ("priority", 0x000D) — bare priority (no project_ prefix) to match the existing project_work_item().priority family edge target. Universal enough to lift across domains if needed.
  • Resolver promoted arm: IssuePriority / issue_priority / Priority / Priorities — explicit promotion is required because IssuePriority lexically lands on issuepriority (not in the codebook), separate from bare priority.

Tests

  • priority_is_the_promoted_canonical_class — shape + language + typed attrs + id 0x000D + back-reference.
  • priority_resolver_collapses_redmine_and_op_issuepriority — every variant (PascalCase/snake_case/plural/bare) shares the same codebook id.
  • ogar-from-rails real-corpus: redmine_and_openproject_issuepriority_converge_through_canonical — both curators' IssuePriority lift to priority / id 0x000D.

Green

ogar-vocab 35 (+2) · ogar-from-ruff 24 · ogar-from-rails 9 real-corpus (+1) · clippy clean · disk 23 GB free.

Codebook at 13 entries (assuming #63 lands)

id concept domain
0x00010x0004 project / project_work_item / billable_work_entry / project_actor project-mgmt
0x00050x0006 project_status / project_type project-mgmt (#63 in flight)
0x00070x000C commercial_line_item / commercial_document / tax_policy / billing_party / payment_record / currency_policy commerce/ERP (merged via #64)
0x000D priority universal (referenced by project_work_item)

Remaining project-mgmt forward references on project_work_item

  • journalsProjectJournal (Redmine Journal ↔ OP Journal)
  • relationsProjectRelation (Redmine IssueRelation ↔ OP Relation)

Both fillable in follow-ups.

🤖 Generated with Claude Code

…priority canonical target)

Continues the OP <-> Redmine ladder closing forward references on
project_work_item family edges. Both curators use IssuePriority <
Enumeration with the universal name/position/is_default triple and a
back-reference has_many :issues/:work_packages to ProjectWorkItem.

- ogar-vocab: priority() canonical class
    HasMany work_items -> ProjectWorkItem (back-reference)
    name (string), position (integer), is_default (boolean)
    Language::Unknown per the synthetic-class doctrine
- CODEBOOK entry: ('priority', 0x000D) — bare 'priority' (no project_
  prefix) to match the existing project_work_item().priority family
  edge target 'Priority'. Universal enough to lift across domains if
  needed; future PRs can rename if commerce needs a distinct Priority.
- canonical_concept resolver: promoted arm for IssuePriority /
  issue_priority / Priority / Priorities — bare 'priority' lexically
  lands on itself but 'IssuePriority' lexically yields the unrelated
  'issuepriority', so explicit promotion is required for the cross-
  curator collapse.

Tests:
- priority_is_the_promoted_canonical_class — shape + language + typed
  attrs + codebook id 0x000D + back-reference to ProjectWorkItem.
- priority_resolver_collapses_redmine_and_op_issuepriority — every
  variant (PascalCase/snake_case/plural/bare) lifts to the same id.
- ogar-from-rails real-corpus: redmine_and_openproject_issuepriority_
  converge_through_canonical iterates both curators' IssuePriority and
  asserts canonical_concept + canonical_id match.

ogar-vocab 35 (+2 priority), ogar-from-ruff 24, real-corpus 9 (+1);
clippy clean; disk 23 GB free.
@AdaWorldAPI AdaWorldAPI merged commit 821cbc1 into main Jun 19, 2026
1 check passed
AdaWorldAPI pushed a commit that referenced this pull request Jun 19, 2026
…mt promotions in one shot

Per direction:
- 'i dont like that you overlap the id without a domain'
- 'if you have project and ERP in one consumer you shouldnt switch
   betweet classids thats not helping'
- 'cant you use the export you have from Ruff to do the canonical
   project labels in one shot'

This addresses all three: domain-prefix the codebook IDs so the high
byte routes on domain, AND batch-promote the surviving cross-curator
overlap from the actual Redmine ↔ OpenProject extract.

DOMAIN-ENCODED CODEBOOK IDs (0xDDCC):
  0x00XX  reserved          (0x0000 = NodeGuid::CLASSID_DEFAULT)
  0x01XX  project-mgmt      (OP ↔ Redmine fork lineage)
  0x02XX  commerce / ERP    (OSB ↔ Odoo)
  0x07XX  reserved: OSINT
  0x08XX  reserved: OCR
  0x09XX  reserved: Health

Renumber the 10 already-merged concepts within the new scheme:
  project              0x0001 -> 0x0101
  project_work_item    0x0002 -> 0x0102
  billable_work_entry  0x0003 -> 0x0103
  project_actor        0x0004 -> 0x0104
  commercial_line_item 0x0007 -> 0x0201
  commercial_document  0x0008 -> 0x0202
  tax_policy           0x0009 -> 0x0203
  billing_party        0x000A -> 0x0204
  payment_record       0x000B -> 0x0205
  currency_policy      0x000C -> 0x0206
Blast radius is contained — codebook is ~1 day old, only internal
OGAR tests use literal IDs, no external consumers persist them. The
'stable forever' contract starts from this commit's id assignments.

Reserved 0x0105/0x0106/0x0107 for in-flight #63/#65 (project_status,
project_type, priority) — those PRs rebase by switching to the
reserved slots.

NEW promotion from the cross-curator overlap probe (Redmine 111 classes
↔ OpenProject 681 classes → 38 common names; 9 chosen by substantive
shape on both sides):
  0x0108  project_membership   (Member)
  0x0109  project_journal      (Journal)
  0x010A  project_repository   (Repository)
  0x010B  project_version      (Version)
  0x010C  project_wiki_page    (WikiPage)
  0x010D  project_query        (Query)
  0x010E  project_attachment   (Attachment)
  0x010F  project_comment      (Comment)
  0x0110  project_custom_field (CustomField)

Each new concept:
- Canonical class function with Language::Unknown, typed attributes,
  and the obvious family edges to existing canonicals (membership ->
  project + actor; journal -> work_item + actor; repository/version/
  wiki_page/query -> project; etc.).
- Resolver arm covering singular/plural/snake_case/PascalCase forms.
- CODEBOOK entry in the 0x01XX project-mgmt block.

NEW types:
- ConceptDomain enum (Reserved / ProjectMgmt / Commerce / Osint / Ocr /
  Health / Unassigned), non_exhaustive, serde-derived under feature.
- canonical_concept_domain(id) -> ConceptDomain: pure O(1) high-byte
  lookup, no table dependency.

5 new tests:
- codebook_ids_are_domain_prefixed_and_consistent — every concept in
  its declared domain block; domain function handles reserved + named
  future blocks.
- project_mgmt_batch_promotions_each_have_a_codebook_id_and_shape —
  each new class has Unknown language, a 0x01XX id, typed attrs.
- project_mgmt_resolver_arms_collapse_curator_names — alias coverage
  for the 9 new concepts (singular/plural/snake/PascalCase).
- Updated commerce_canonical_classes test for new 0x02XX ids.
- Updated wire_synergies_links test from Comment/comments (now
  promoted to project_comment) to Setting/settings (still lexical).

ogar-vocab 36 (+5), ogar-from-ruff 24, real-corpus 8; clippy clean.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants