Configurable Tab context for inline completions in niche languages / DSLs

Feature request for product/service

Tab

Describe the request

Cursor Tab works well in mainstream languages, but it becomes unreliable in DSLs and niche file types where the model has weaker training coverage, such as SAP CAP CDS. In those files, inline completions often look plausible at first glance but produce invalid syntax or patterns that do not compile.

The core issue is that Cursor Tab cannot be guided in the same practical way as Agent workflows. Teams can encode rules and constraints for chat/agent behavior, but that does not reliably help inline prediction, so users either accept noisy completions or disable Tab entirely for those file types.

Proposed solution

Add an optional, configurable short Tab context field (~1000 characters) that is injected into the Cursor Tab / inline prediction request. This context should be:

  • Short, stable, and explicit
  • Configurable per workspace and/or per user
  • Scopable by language ID and/or glob pattern (e.g. cds or **/*.cds)
  • Independent from Agent Rules, so chat/agent workflows remain unchanged

Example config shape

{
  "cursor.tabContext": [
    {
      "languageId": "cds",
      "glob": "**/*.cds",
      "context": "Generate only valid SAP CAP CDS syntax. Prefer existing vocabularies and patterns in this workspace. Do not invent annotations or keywords."
    }
  ]
}

Who this is for

Anyone working in medium- or low-coverage languages, internal DSLs, schema-driven configs, or file types where invalid inline completions create more noise than value.

Desired outcome

Better inline suggestions in niche languages without turning Cursor Tab off entirely, while preserving the existing Agent/Rules model for chat and agent workflows.

Hi @sleibach Thanks for the feature request. There isn’t currently a dedicated per-language “Tab context” setting like the one you described, but there are a couple of workarounds that may help immediately:

  1. Add a short comment header in the relevant .cds files with the constraints you want Tab to follow. Since Tab uses nearby file context, this can help bias suggestions toward valid SAP CAP CDS syntax and your project’s conventions.

  2. Keep a small examples or patterns file in the workspace with valid SAP CAP CDS examples, preferred annotations, and common structures. Tab generally performs better when the workspace contains representative patterns it can draw from.

Your proposed scoped Tab context setting makes sense as a feature request, especially for niche DSLs where syntactic validity matters more than plausible-looking completions. As we do have a lot of competing priorities and workstreams, I’m not able to raise this as a feature request at the moment (but if it gets a lot of traction but other users its something we can consider down the road).