Omniscio

Team Chat — turning

A workspace owner or admin can add up to twenty auto-link rules. Each rule is a pattern, such as #(\d+), plus the web address a match should open, such as a tracker issue URL built from what the pattern captured. From then on, everyone in that workspace sees those references in a message as working links, in the same text they typed. Rules never touch code blocks or a link someone already wrote, and a pattern that is too expensive to match safely is refused with an explanation.

On this page

What it does

A workspace owner or admin writes rules. A rule is two things:

  • a pattern — plain text with optional bracketed groups, for example #(\d+) for a number sign followed by digits; and
  • a web address — the page a match opens, with {1}, {2} and so on standing for what the pattern's groups captured, for example https://github.com/your-team/your-repo/issues/{1}.

From then on, anyone in that workspace who writes #123 in a message sees it as a link to https://github.com/your-team/your-repo/issues/123. The message text itself never changes: the same characters are stored, and only the display becomes a link. A person who does not have the workspace's rules sees the plain text.

This is the same idea Slack and Zulip call a linkifier, and it works for any tracker with a predictable web address — GitHub, GitLab, Jira, Linear, a bug tracker of your own.

Who can set it up

A workspace owner or admin. The section lives in Workspace settings, on the General tab, under Tracker auto-links. Everybody else in the workspace can use the rules but cannot see or change the setup.

Adding a rule

  1. Open Workspace settings → General.
  2. Press Add rule under Tracker auto-links.
  3. Type the pattern — for example #(\d+).
  4. Type the web address, using {1} where the captured number should go.
  5. Press Add rule to save it.

A saved rule shows its pattern and address, with Edit and Remove beside it. Removing asks you to confirm first. Messages already sent are never changed by adding, editing or removing a rule — they simply render with whatever rules the workspace has when they are read.

What a pattern can do

  • Plain text matches literally, and matching ignores upper and lower case, so PR-(\d+) also finds pr-42.
  • Brackets capture a part of the match, so {1} can put it in the address. A pattern may use up to nine bracketed groups.
  • \d means a digit, \w a letter, digit or underscore, and + means one or more. These are the ordinary pattern characters most trackers and search boxes use.
  • A partial match still links. #(\d+) inside see #12 for details links the #12 and leaves the rest of the sentence exactly as it was.
  • The first matching rule wins when two rules would match at the same place, and the rule whose match starts earliest wins over one that starts later.

Why some patterns are refused

The pattern is run against every message as it is displayed, so the app refuses a pattern that could take a very long time to evaluate — one with a repeated group inside another repeat (such as (a+)+), a repeated alternative (such as (a|b)+), two repeat marks with nothing required between them (such as \d+\d+), a back-reference (such as (\d)\1 or (?<n>\d)\k<n>), or a look-ahead or look-behind. Each of these invites a pattern that could freeze the screen on a long message. A pattern that can match nothing at all is refused too, and so is an address that does not start with http:// or https:// once the captured text is filled in. The app says which problem it found under the box that caused it, so the rule can be fixed before saving.

Captured text is always URL-encoded when it is placed into the address, so a stray /, ?, & or # in a message can never change the shape of the link.

Limits

  • Twenty rules per workspace. The section says so once the last one is in, and stops offering to add another until one is removed; the save itself refuses a twenty-first rule, so two admins cannot slip past the cap together.
  • 200 characters per pattern and 500 per web address.
  • Nine bracketed groups per pattern.
  • Rules apply in the order they were added, and when two rules match at the same place the earlier one in that order wins.
  • A single stretch of text longer than 1,000 characters is not scanned, so a very long paste costs the same on every machine. Anything shorter, which is every ordinary message, is scanned normally.
  • Code and existing links are never touched. A reference inside inline code or a code block stays literal, and a link someone already wrote is never wrapped in a second link.

Where the rules do not reach

The rules are read when a conversation opens and are used by the desktop app's message body. The phone web app is a separate renderer and does not apply workspace auto-link rules; it shows the same message as plain text and its own automatic web links. Agent messages, alerts and search results are not message bodies and are not rewritten.

For developers

  • Validation and splitting are pure and shared: validateAutoLinkRule, validateAutoLinkRuleList, normalizeAutoLinkRule, prepareAutoLinkRules, splitAutoLinks and splitAutoLinksPrepared in src/shared/team-chat/auto-links.ts. The list is capped at AUTO_LINK_RULE_MAX.
  • The render step is a remark plugin: topicAutoLinksRemark(rules) in src/renderer/src/features/team-chat/topic-auto-links-remark.ts turns matches inside text nodes into link nodes and skips link, linkReference, inlineCode, code, html, definition, image and imageReference.
  • Storage: one document per rule at <workspace root>/autoLinks/<ruleId> with pattern, urlTemplate, createdBy and createdAt; path builders live in src/shared/team-chat/auto-link-paths.ts. Any member reads; only a workspace owner or admin writes.
  • The rules reach the message body through a small store, not a prop: auto-link-rules-store.ts exposes setActiveAutoLinkRules / useActiveAutoLinkRules, the hook above writes into it, and the message body reads it, so no rule list has to be threaded through the message row and body components. The plugin goes LAST in the remark list, after the mention, channel, item and emoji steps, so a rule can never steal text those chips need.
  • Reads are bounded and cached: useWorkspaceAutoLinks does one limit(20) query ordered by createdAt per workspace when a surface asks for it, caches the answer in memory for five minutes, shares an in-flight read, and treats permission-denied as "this workspace does not have the feature" rather than as an error. A failed read reports itself (failed) so the section says so and offers Try again instead of claiming the workspace has no rules.
  • The scan is bounded: AUTO_LINK_TEXT_MAX (1,000 characters) stops a very long text node from being scanned at all, and the validator refuses the pattern shapes that could backtrack catastrophically, so no admin-authored rule can pin the render thread.

Last verified 2026-11-21