Skip to content

0.40.0

Choose a tag to compare

@cliftonc cliftonc released this 19 Nov 10:11
· 99 commits to main since this release
0.40.0
bc06e26

Knowledge facts are built only from documents a reader may see and settled only by those allowed, invitations follow their issuer, suspended organisations run no queued jobs, the chunker runs in linear bounded work, and security reports publish counts only.

  • Extraction prompt and decision-model material (known entities, accepted facts, held values) come from tenant-visible documents only, whatever the document being read (services/knowledge/extract.ts, promptScope).
  • ResolveContext gains a required documentVisibility; a groups document adds no aliases to the entity it links to or creates (services/knowledge/entities.ts).
  • A fact superseded only by a fact the reader cannot see reads as its restored state with supersededById: null, and is answerable in lookup_facts, counted in GET /api/knowledge/entities and reviewable by that reader; confirm keeps the stored superseded state (facts-sql.ts supersededOutOfViewSql / stateInViewSql, facts-read.ts, review.ts).
  • findEntitiesByName and entitiesMentionedIn take the reader's AccessScope instead of a tenant id and return only staging entities the reader may see, so lookup_facts answers an entity known only from hidden documents like an unknown name.
  • hasPendingInvitation (services/auth.ts) counts an open invitation only when issuerMayIssue (services/invitations.ts, the rule accept already applied) holds for its issuer: not blocked, and a global admin or a member whose role could issue it.
  • setUserBlocked (services/admin.ts) revokes every pending invitation the person issued, in every tenant, in the block's transaction (revokeEveryInvitationIssuedBy); unblocking restores none.
  • The jobs consumer (queues/jobs.ts) reads tenants.status for every job whose payload names a tenant and acks it unrun unless the tenant is active; tenant.purge and activity.record always run, plugin jobs follow the same rule.
  • A dropped document.index / document.convert leaves a pending document failed, so Retry picks it up after reactivation. Rationale: docs/CONCEPTS.md §1.
  • public-report's entries file is { repos, runs[{ date, commit, scope, coverage_units, agent_calls, confirmed: { high, medium, low }, fixed_in: [release] }], fixed[{ release, repo, high, medium, low, hardening }], contact? }; critical is an optional count.
  • The findings and hardening lists and every line are gone; line, title, description or any unknown field refuses the whole file, as do a count with no fixing release, a negative or fractional count, or a repo not in repos.
  • report.md/report.json carry a fixed sentence: individual issues are not published, "Please request the detailed report by emailing " (default security@rocketflare.dev).
  • SKILL.md "Public report", docs/SECURITY-AUDIT.md, docs/CONCEPTS.md (rf-security) and SECURITY.md state that only counts are ever published.
  • POST /api/knowledge/facts/:id/review { action: 'prefer' } by a member who cannot manage knowledge is a 403 fact_conflict_needs_admin, with nothing written, when a visible conflict is reviewed by someone else, has no reviewer, or was confirmed by another person. An admin still settles any conflict, and the member can still reject their own side.
  • New error code fact_conflict_needs_admin in @rocketflare/shared/errors.
  • chunking.ts recognises ATX headings and GFM delimiter rows with a linear scan instead of a regex. Every heading and delimiter row is recognised exactly as before.
  • A table header wider than a quarter of the chunk window is carried as its first columns plus …, so header and rows fit one window. A header wider than a window is split into windows of its own. Narrower headers are carried whole, as before.
  • embeddingInput cuts the heading path and table header it prefixes to EMBEDDING_CONTEXT_MAX_CHARS (1600) and never cuts the chunk text. A heading title is cut to HEADING_TITLE_MAX_CHARS (200) in headingPath.
  • docs/DEPLOY.md § Observability now matches the tomls (invocation_logs = true) and says invocation logs record each request's URL.
  • Why: docs/CONCEPTS.md §9, the chunking paragraph and the knowledge review endpoints.
  • Rationale: docs/CONCEPTS.md §9 "Knowledge facts" (extraction and "Reading facts").

Porting note: docs/upgrades/0.40.0.md

Full changes: 0.39.0...0.40.0