Skip to content

The REACH DSL

A .reach file is a domain-specific language. The domain is intent — what to reach into, over what timeframe, with what analysis goal. The language doesn't know about COM Interop, NuGet packages, or SQL client libraries. Those are implementation. The DSL knows about sources, qualifiers, and outputs.

You write the vocabulary. Claude compiles the implementation.


Syntax Shape

reach <source>
  <qualifier>  <value>
  <qualifier>  <value>
  <action>     <value>
  output       <format>

Multiple sources compose with +:

reach <source-a> + <source-b> + <source-c>
  since     <timeframe>
  analyze   <intent>
  output    <format>

Everything lowercase. Indentation two spaces. Quoted strings for values with spaces.


Source Vocabulary

Outlook

reach outlook.inbox
  where     subject contains "[PROJECT]"
  since     start-of-year
  group by  month
  output    cadence
reach outlook.calendar
  since     10-weeks-ago
  analyze   density
  group by  week
  output    summary
reach outlook.sent
  where     subject contains "[PROJECT]"
  since     start-of-year
  group by  month
  output    cadence
reach outlook.folder "Deleted Items"
  count     all
  output    summary

Git

reach git.commits
  since     10-weeks-ago
  analyze   after-hours
  benchmark 15%
  output    report
reach git.log
  since     start-of-month
  format    author + date + message
  output    table

Screen

reach screen
  save as   snapshot

reach screen.window "Chrome"
  save as   snapshot

reach screen.region 0 0 1920 1080
  save as   snapshot

Browser

reach browser.page "https://staging.internal/deployments"
  wait for  ".deployment-status"
  extract   text
  output    summary
reach browser.auth "https://internal-tool/login"
  field     "#username" "myuser"
  field     "#password" "mypass"
  submit    "button[type=submit]"
  then      browser.page "https://internal-tool/dashboard"
  extract   text
  output    summary

Database

reach db.query
  env       staging
  sql       "SELECT TOP 100 * FROM Equipment WHERE Status = 'Active'"
  output    json
reach db.table Equipment
  env       staging
  sample    20
  output    summary

Files

reach file.read "attachments/report.docx"
  extract   text
  output    plain
reach file.merge "attachments/*.txt"
  separator "---"
  output    "merged_context.txt"
reach file.watch "C:\reach\attachments"
  on new    signal "file-arrived"
  output    log

UI Automation

reach ui.window "OUTLOOK"
  find      name "Inbox"
  read      items
  output    list

HTTP

reach http.get "https://internal-api/deployment/status"
  output    json

Qualifier Vocabulary

QualifierApplies toMeaning
whereoutlook., db.Filter condition
sinceoutlook., git., calendarTime range start
untiloutlook., git., calendarTime range end
group byanyGroup results by dimension
analyzeanyNamed analysis intent
benchmarkgit.commits, any metricTarget value for comparison
wait forbrowser.*CSS selector to wait for
extractbrowser., file.What to pull — text, table, links
findui.*Control to locate by name or type
envdb.*Named environment (dev/staging/prod)
sampledb.*Number of rows to sample
save asscreen.*Output filename
on newfile.watchEvent trigger
mergefile.*Combine multiple file outputs
countanyCount items instead of listing them

Output Vocabulary

OutputWhat you get
summaryClaude narrates what it found
cadenceFrequency pattern over time — counts by period
reportStructured findings with interpretation
jsonRaw JSON to stdout
tableFormatted table
listLine-by-line items
plainPlain text extraction
snapshotImage file — Claude reads inline
logAppend to run log
signalWrite signal file for another reach

Analyze Vocabulary

Named analysis intents Claude understands:

ValueWhat Claude does
cadenceGroups by time period, identifies patterns, gaps, spikes
after-hoursSplits activity by time of day, calculates % outside core hours
densityMeasures concentration — meetings per week, emails per day
rpmReads combined signal across sources, calls green/yellow/red/all-red
velocityRate of output over time
sentimentTone pattern across communications
recoveryWhat it would take to normalize current state
summaryPlain language synthesis

Timeframe Vocabulary

ValueMeaning
todayCurrent day
this-weekMonday to now
last-weekPrevious full week
start-of-monthFirst day of current month
start-of-yearJanuary 1
10-weeks-agoN weeks before today
30-days-agoN days before today
"2026-01-01"Explicit date

Composition — The Most Powerful Operator

+ between sources is the most powerful operator in the language. Each source reaches independently; Claude holds all results in context and synthesizes across them.

reach outlook.inbox + outlook.calendar + git.commits
  since     10-weeks-ago
  analyze   rpm
  benchmark after-hours 15%
  output    report

This is the sprint cadence review in one block. Claude reaches into all three sources, reads the combined signal, calls the RPM state, flags the after-hours against the benchmark, and delivers a narrative report.


The Pause Layer — Prompts and Gates

REACH has three modes. The pause layer is what separates reads from writes:

READ    →  runs freely, no prompt
ACT     →  low risk, may run freely
PAUSE   →  write gate — Windows UI surfaces, human approves

prompt.confirm

reach outlook.draft
  to        "[email protected]"
  subject   "Sprint Summary — {date}"
  body      from git.commits since today
  then      prompt.confirm
    title   "Send this email?"
    on yes  outlook.send
    on no   outlook.save-draft

prompt.preview

reach outlook.draft
  to      "[email protected]"
  subject "Daily Summary — {date}"
  body    from git.commits + outlook.inbox since today analyze summary
  then    prompt.preview
    title   "Email draft ready"
    actions send | edit | save-draft | discard
    on send       outlook.send
    on save-draft outlook.save

prompt.form

reach timesystem.timesheet
  then  prompt.form
    title  "Review timesheet entries"
    fields
      request-id   text      "Request ID"
      start-time   time      "Start"
      end-time     time      "End"
      description  textarea  "Description"
    on submit  timesystem.post
    on cancel  outlook.save-draft

The prompt layer is the conscience of the automation. Reads run freely. Writes pause. no-prompt is an explicit override — never a default.


Named Reaches — Reusable Patterns

# sprint-review.reach

name        sprint-cadence-review
description Read sprint health across email, calendar, and commits

reach outlook.inbox + outlook.calendar + git.commits
  since     10-weeks-ago
  analyze   rpm
  benchmark after-hours 15%
  output    report

Run it:

bash
dotnet reach sprint-review.reach

Share it. Fork it. Someone changes the project filter and runs it against their data. The pattern travels as a file.


The Compilation Model

You write          →  sprint-review.reach
Claude reads DSL   →  understands intent per source block
Claude generates   →  typed C# per source (NuGet chosen per block)
dotnet run         →  executes each reach
prompt surfaces    →  if write action — Windows UI appears, human decides
results flow back  →  Claude synthesizes across all sources
artifact written   →  sprint-review.reach-artifact

You never see the NuGet package names, the COM Interop calls, the Playwright instantiation, or the WinForms boilerplate. Just intent. Just results. Just the right pause at the right moment.


Design Principles

Reads like intent, not code — Anyone can read a .reach file and understand what it does. No training required.

Sources are the vocabulary, not the implementationoutlook.inbox is a concept. How Claude reaches it is Claude's decision, not yours.

Composition is first-class+ between sources is the most powerful operator. The sprint review, the timesheet draft, the deployment check — all compositions of simple sources.

Artifacts outlast sessions — Every meaningful reach produces a .reach-artifact. The finding is permanent even though the script is ephemeral.

Benchmarks make findings actionablebenchmark after-hours 15% turns a number into a verdict. Claude doesn't just report 30% — it calls it against the target.

Writes pause by default — The prompt layer is not optional. It is the design.