Extract Coding Standards

Extract Coding Standards

Have your agent identify the coding standards that already exist in this repo, then sync them to Gloria so they can be reused across projects.

1. Have your agent identify coding standards

Ask your agent: “Extract our coding standards and register them with gloria.”

Your agent looks through the repo’s configs, written guidance, and repeated source patterns. It turns those into rules and snippets your team can reuse later. Rules are the instructions your agent should follow. Snippets are the canonical examples your agent can copy or adapt when writing code.

2. Sync the standards with Gloria

Ask your agent: “Register the standards with Gloria.”

Gloria stores the rules and snippets your agent can use, so future code stays aligned with your project’s standards. You only need to do this once per project, and your agent can use the same standards every time it writes in this repo.

3. Review the synced rules and snippets in Gloria

Open Coding Standards in the web app after the sync finishes. On the Rules page, expand each table to review the extracted rules, check each rule’s status inline, and use the visible companion prompt if your agent needs to run the extraction again. When you need to share or revisit one rule, use its direct link so Gloria opens the right section and lands on that rule.

Use the Snippets page to review the canonical examples your agent extracted. Sort the table, filter it by language, and open a snippet page to inspect the example, copy the code, or follow the link back to the related rule. When Gloria recognizes the snippet language, the page shows highlighted code. If the language is missing or unclear, the page still shows the snippet as plain text.

4. Check your code against your coding standards to prevent drift

Ask your agent: “Check my code against the coding standards.”

Your agent compares the code to the registered standards and points out drift before it spreads. That makes it easier to keep the repo aligned with the conventions you want.

Next