Skip to content

docs(engine): add a Tenant quota README section - #5860

Merged
loopover-orb[bot] merged 1 commit into
JSONbored:mainfrom
davion-knight:docs-engine-tenant-quota-readme
Jul 14, 2026
Merged

docs(engine): add a Tenant quota README section#5860
loopover-orb[bot] merged 1 commit into
JSONbored:mainfrom
davion-knight:docs-engine-tenant-quota-readme

Conversation

@davion-knight

Copy link
Copy Markdown
Contributor

Closes #5815.

Adds a ## Tenant quota section to packages/loopover-engine/README.md documenting tenant-quota.ts (landed in #5801), in the same style as the package README's other pure-decision-module sections.

Docs-only — a single .md file, no code changed. Per codecov.yml, coverage is collected only over src/** / packages/loopover-engine/src/** / packages/loopover-miner/lib/**, so no Codecov gate fires (expected).

Deliverable

The new section documents:

  • What evaluateTenantQuota(usage, quota) decides — allowed + first-exhausted QuotaDimension + user-facing reason + per-dimension remaining headroom.
  • The TenantQuota / TenantUsage / QuotaDimension / TenantQuotaDecision shapes (field names verified against the exports).
  • The module's decision-only scope boundary (it does not store usage, meter compute, or stop a loop — enforcement is separate/maintainer-owned), mirroring how neighboring governor sections flag the same.
  • A passing and a blocked usage snippet whose commented output was captured by running the module's actual logic (fixed compute→time→concurrency precedence, >=-cap exhaustion, non-negative-integer normalization).

Validation

  • Field names cross-checked against tenant-quota.ts exports (TenantQuota/TenantUsage/QuotaDimension/TenantQuotaDecision).
  • The snippet's two commented decision outputs were produced by executing the evaluator's real logic, so the remaining numbers and the exact reason string match current behavior.

Document the pure per-tenant resource-quota evaluator (tenant-quota.ts):
what evaluateTenantQuota decides (allowed + first-exhausted dimension +
reason + remaining headroom), the TenantQuota/TenantUsage/QuotaDimension/
TenantQuotaDecision shapes, its decision-only scope boundary, and a
verified passing/blocked usage snippet — matching the style of the
package README's other pure-module sections.

Closes JSONbored#5815
@davion-knight
davion-knight requested a review from JSONbored as a code owner July 14, 2026 20:03
@superagent-security

Copy link
Copy Markdown
Contributor

Superagent didn't find any vulnerabilities or security issues in this PR.

@loopover-orb loopover-orb Bot added the gittensor:feature Gittensor-scored feature linked to a feature issue — scores a 0.25x multiplier. label Jul 14, 2026
@loopover-orb

loopover-orb Bot commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

Tip

🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩

✅ LoopOver review result - approve/merge recommended

Review updated: 2026-07-14 20:10:56 UTC

1 file · 1 AI reviewer · no blockers · readiness 100/100 · CI green · clean

✅ Suggested Action - Approve/Merge

  • safe to merge

Review summary
Docs-only PR adding a '## Tenant quota' README section documenting evaluateTenantQuota from tenant-quota.ts, following the same structure as the existing governor sections above it. I traced both snippet outputs against the actual evaluateTenantQuota implementation shown in context and both the allowed and blocked decision objects (including exact remaining values and the reason string) match the real logic precisely. The type field lists (TenantQuota, TenantUsage, QuotaDimension, TenantQuotaDecision) also match the exported types exactly.

Nits — 3 non-blocking
  • The import in the snippet uses `@​loopover/engine` (README.md:+16); worth double-checking this matches the actual package export name used elsewhere in the README rather than a raw relative import path.
  • The new section duplicates the 'decision-only, does not store usage / meter compute / stop a loop' framing already present in prose form in tenant-quota.ts's own header comment — fine for a README but worth trimming if the file's length (~720 lines) becomes a maintenance concern.
  • Consider linking to tenant-quota.ts directly (e.g. a relative markdown link) as some other module sections may already do, for easier navigation.
Signal Result Evidence
Code review ✅ No blockers 1 reviewer
Linked issue ✅ Linked #5815
Related work ✅ No active overlap found No same-issue or scoped active PR overlap found.
Change scope ✅ 20/20 Low review scope from cached public metadata (1 linked issue).
Validation posture ✅ 25/25 PR body includes validation/test evidence.
Contributor workload ✅ 10/10 Author activity: 121 registered-repo PR(s), 86 merged, 0 issue(s).
Contributor context ✅ Confirmed Gittensor contributor davion-knight; Gittensor profile; 121 PR(s), 0 issue(s).
Gate result ✅ Passing No configured blocker found.
Improvement ⚠️ ℹ️ Insufficient signal risk: clean · value: insufficient-signal — Nothing measurable for the structural-improvement analyzers on this PR (e.g. no code files changed).
Review context
  • Author: davion-knight
  • Role context: outside_contributor
  • Public audience mode: oss maintainer
  • Lane context: Repository is configured for direct PR review.
  • Public profile languages: not available
  • Official Gittensor activity: 121 PR(s), 0 issue(s).
  • PR-specific overlap: none found.
Contributor next steps
  • Keep the PR focused and include validation evidence before maintainer review.
Signal definitions
  • Related work = same linked issue, overlapping active PRs, or title/path similarity.
  • Change scope = cached public metadata such as size labels, draft state, and review-burden hints.
  • Validation posture = whether the PR provides enough public validation/test evidence for maintainer review.
  • Contributor workload = public contributor activity and cleanup pressure, not a repo-wide quality failure.
  • Contributor context = public GitHub/Gittensor identity context; non-Gittensor status is not a blocker.
[BETA] Chat with Gittensory

Ask Gittensory a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.

  • @gittensory ask <question> answers contribution-quality Q&A with source citations and freshness.
  • @gittensory chat <question> answers in natural prose from cached decision-pack facts via local inference (maintainer/collaborator; read-only).
  • A plain-language @gittensory mention with a real question is routed to the closest matching read-only command automatically -- no exact syntax required.

Full command reference: https://gittensory.aethereal.dev/docs/gittensory-commands

🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed


💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →.

Checked by LoopOver, a quiet PR intelligence layer for OSS maintainers.

  • Re-run LoopOver review

@loopover-orb loopover-orb Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gittensory approves — the gate is satisfied and CI is green.

@loopover-orb
loopover-orb Bot merged commit c290235 into JSONbored:main Jul 14, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gittensor:feature Gittensor-scored feature linked to a feature issue — scores a 0.25x multiplier.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

docs(engine): add a README section for tenant-quota.ts

1 participant