🤖 AI & IDE Integration (llms.txt)
To ensure modern AI coding assistants—such as Cursor, VS Code (GitHub Copilot), Antigravity, ChatGPT, and Claude—generate accurate, idiomatically aligned Tempo code and minimize hallucinations, Tempo publishes an official, standardized llms.txt rulebook.
By providing these rules to your AI assistant, your IDE will respect Tempo's strict immutability, zero-cost getters, native Temporal runtime expectations, and layout token syntax out-of-the-box.
🚀 Quick Setup by IDE / Tool
1. Cursor IDE
Add Tempo to Cursor's native documentation index:
- Open Cursor Settings (
Cmd + ,orCtrl + ,). - Navigate to Features ➔ Docs.
- Click + Add new doc and enter:
- Name:
Tempo - URL:
https://tempo.magmacomputing.com.au/llms.txt
- Name:
TIP
Once added, type @Tempo in any Cursor chat or prompt window to inject exact API syntax rules into your conversation.
2. VS Code & GitHub Copilot
In VS Code, configure GitHub Copilot Chat by adding a .github/copilot-instructions.md file to the root of your workspace:
# Tempo AI Rules
- Always use `Tempo` from `@magmacomputing/tempo`.
- Never instantiate legacy JavaScript `Date`. Tempo expects native `Temporal` or polyfill.
- All mutating methods (`.add()`, `.subtract()`, `.set()`) return a brand-new, frozen `Tempo` instance.
- Refer to https://tempo.magmacomputing.com.au/llms.txt for full layout token grammar.When prompting Copilot Chat in VS Code:
"Using https://tempo.magmacomputing.com.au/llms.txt, write a custom layout parser..."3. Antigravity AI Assistant
In Antigravity, you can reference the live endpoint directly in your chat prompt or store it as a localized Knowledge Item (KI):
- Reference
@https://tempo.magmacomputing.com.au/llms.txtin your prompt for instant context ingestion.
4. ChatGPT & Claude Projects
For web-based LLM interfaces, reference or copy-paste the full, un-truncated documentation context file: 👉 Full RAG Documentation Bundle (llms-full.txt)
🛠️ Prompting AI for Custom Layout Extensions
When asking AI assistants to generate custom layout patterns for non-standard date-time formats, instruct the model to use Tempo's configuration syntax (Tempo.init({ registry: { layouts: { ... } } })) and layout tokens ({yy}, {mm}, {dd}, {hh}, {mi}, {ss}).
Sample Prompt:
"Using the rules from https://tempo.magmacomputing.com.au/llms.txt, register a custom Tempo layout for star-delimited dates (e.g., '08042026') using
Tempo.init({ registry: { layouts: { ... } } })and parse the date string usingnew Tempo(...)."
Generated Code (Actual Tempo Syntax):
import { Tempo } from '@magmacomputing/tempo';
// 1. Register custom layout pattern using layout tokens
Tempo.init({
registry: {
layouts: {
star_date: '{mm}\\*{dd}\\*{yy}'
}
}
});
// 2. Parse date string matching the custom layout
const date = new Tempo('08*04*2026');