Skip to content

Instantly share code, notes, and snippets.

@johnlindquist
Created December 7, 2025 20:16
Show Gist options
  • Select an option

  • Save johnlindquist/44a82678b9d02bdba589828813ea4733 to your computer and use it in GitHub Desktop.

Select an option

Save johnlindquist/44a82678b9d02bdba589828813ea4733 to your computer and use it in GitHub Desktop.
Microsoft AI Dev Days Talk: Scripting Copilot - Piping Hot Intelligence (Unix History Journey)

Scripting Copilot: Piping Hot Intelligence

Microsoft AI Dev Days Talk (15-20 min)

Angle: Unix History Journey - From Doug McIlroy 1978 to AI Pipelines 2025


ACT 1: THE HOOK (1-2 minutes)

Opening: The One-Liner That Changed Everything

Slide: Black terminal, green text, cursor blinking

Say this:

"Before I show you the future, let me show you something."

$ ma task.copilot.md

Pause. Let it breathe.

"That markdown file just ran an AI agent. But the really interesting part? I stole this idea from 1978."

Transition:

"Let me take you back. Way back."


ACT 2: MAIN CONTENT - THE HISTORY JOURNEY (12-15 minutes)

Section 2.1: 1978 - Doug McIlroy's Prophecy (2-3 min)

Slide: Black and white photo of Doug McIlroy at Bell Labs

The Quote (let it land):

"Write programs that do one thing and do it well. Write programs to work together. Write programs to handle text streams, because that is a universal interface."

-- Doug McIlroy, 1978

The First Pipe:

# Bell Labs, 1973 - Ken Thompson implements the pipe
who | wc -l

What made this revolutionary:

  • Programs don't need to know about each other
  • Text flows between them like water through pipes
  • Composition over complexity
  • Small, sharp tools combined infinitely

Key insight:

"McIlroy didn't just create a feature. He created a philosophy. And that philosophy survived every paradigm shift since."


Section 2.2: The Evolution - 50 Years of Pipes (2 min)

Slide: Timeline graphic - 1973 to 2025

1973 - The First Pipe:

who | wc -l

1980s - Text Processing Era:

cat access.log | grep ERROR | sort | uniq -c | sort -rn

1990s - Scripting Age:

find . -name "*.c" | xargs grep "malloc" | wc -l

2000s - Web Data:

curl api.example.com | jq '.users[]' | head -10

2010s - DevOps Pipelines:

git diff | terraform plan | tee changes.txt

2025 - Intelligence Flows:

git diff | copilot -p "review this code" -s

"Same operator. Same philosophy. Fifty years of evolution, and the pipe is still the answer."


Section 2.3: The New Ingredient - GitHub Copilot CLI (8-10 min)

Slide: The pipe symbol | transforming into a neural pathway

Part A: Non-Interactive Mode (2 min)

The key flags that unlock everything:

# Interactive (default) - can't pipe
copilot

# Non-interactive with prompt - CAN pipe
copilot -p "explain what a mutex does"

Why -p matters:

"Without -p, Copilot expects a human. With -p, Copilot expects a pipe. This is the breakthrough."

DEMO 1: The Simplest AI Pipe

# Data in, intelligence out
echo "explain recursion in one sentence" | copilot -p "answer this"

Part B: The Star of the Show - Piping (3-4 min)

Slide: Doug McIlroy's quote side-by-side with modern pipeline

The Pattern McIlroy Would Recognize:

# 1978 style: data | transform | output
cat server.log | grep ERROR | wc -l

# 2025 style: data | intelligence | output
cat server.log | copilot -p "find the root cause" -s

DEMO 2: Git Diff Review (The Crowd-Pleaser)

git diff | copilot -p "review this for bugs and security issues" -s

Build the pipeline:

# Stage 1: Extract
git diff | copilot -p "list all changed functions" -s

# Stage 2: Transform
git diff | copilot -p "list changes" -s | copilot -p "rank by risk" -s

# Stage 3: Format
git diff | copilot -p "list changes" -s | \
  copilot -p "rank by risk" -s | \
  copilot -p "format as markdown table" -s

The Unix Revelation:

"McIlroy's text streams became AI pipelines. grep filters text. Copilot filters... meaning."


Part C: Model Escalation - Right Tool for the Job (2 min)

Slide: Wrench set with different sizes

The Unix Principle Applies:

"Use cat when you need cat. Use awk when you need awk. Use haiku when you need speed, opus when you need depth."

# Fast and cheap - triage, classification
copilot -p "is this urgent?" --model claude-haiku-4.5

# Balanced - daily work
copilot -p "review this code" --model claude-sonnet-4

# Deep analysis - architecture, complex debugging
copilot -p "design the auth system" --model claude-opus-4.5

DEMO 3: The Escalation Pattern

# Let the light model decide if you need the heavy model
COMPLEXITY=$(echo "$TASK" | copilot -p "SIMPLE or COMPLEX? One word." --model claude-haiku-4.5)

if [ "$COMPLEXITY" = "COMPLEX" ]; then
  copilot -p "$TASK" --model claude-opus-4.5
else
  copilot -p "$TASK" --model claude-haiku-4.5
fi

"Haiku costs a fraction of Opus. Let the cheap model triage so the expensive model can focus."


Part D: Permission Boundaries - Least Privilege (2 min)

Slide: A valve on a pipe with a permission lock

The Unix Security Model, Evolved:

# Read-only - safe for any pipeline
copilot -p "analyze this codebase" --allow-tool 'shell(git:*)'

# Git operations only
copilot -p "create a commit message" --allow-tool 'shell(git:*)'

# Full autonomy (use with caution)
copilot -p "refactor the auth module" --allow-all-tools

DEMO 4: Controlled Intelligence

# Safe: can read, can't write
git diff | copilot -p "find security issues" \
  --allow-tool 'shell(git:*)' \
  --allow-tool Read

The McIlroy Connection:

"Unix had permissions on files. We have permissions on actions. Same principle: least privilege."


Section 2.4: The Problem - 1978 Meets 2025 (1 min)

Slide: Scribbled notes vs. clean documentation

"McIlroy wrote his philosophy down. He documented it. That's why we still follow it 50 years later."

Pain points:

  • These pipelines are powerful but ephemeral
  • Flag combinations disappear from memory
  • Team knowledge stays in one person's head
  • Slack messages don't scale

Transition:

"What if we could write our AI pipelines down... in the most readable format ever invented?"


ACT 3: THE RESOLUTION - markdown-agent (3-4 minutes)

The Reveal

Slide: Markdown file icon with a play button

$ ma task.copilot.md

What Just Happened:

  • Markdown file = Agent definition
  • YAML frontmatter = Configuration
  • Body = The prompt (your instructions)
  • .copilot in filename = Run with Copilot CLI

"McIlroy documented the Unix philosophy in plain text. We document AI workflows in markdown."


A Complete Agent File

File: review.copilot.md

---
model: claude-sonnet-4
allow-tool:
  - 'shell(git:*)'
  - Read
---

Review this code for:
1. Security vulnerabilities
2. Performance issues
3. Logic errors

Prioritize findings by severity.
Format as a markdown checklist.

Usage:

git diff | ma review.copilot.md

The Full Power: Imports and Templates

File: analyze.copilot.md

---
model: claude-opus-4.5
args:
  - focus
---

## The Codebase
@./src/**/*.ts

## Your Task
Analyze this code with focus on {{ focus | default: "overall quality" }}.

## Previous Analysis
!`git log --oneline -5`

Usage:

ma analyze.copilot.md --focus "authentication flow"

The Pattern:

  • @./path - Import files (like #include)
  • !command`` - Inline command output
  • {{ variable }} - Template substitution

The Equation That Changed

Slide: Two equations side by side

1978:

Software = Code + Data

2025:

Software = Instructions + Tools

"McIlroy gave us composition. Markdown gives us readability. AI gives us intelligence. The pipe connects them all."


CLOSING (1 minute)

The Through-Line

Slide: Timeline from 1978 to 2025, ending at a pipe symbol

Final thought:

"Doug McIlroy didn't know about large language models. But he knew about text. He knew about composition. He knew that small, sharp tools combined simply would outlast any monolithic solution."

"Fifty years later, his philosophy doesn't just survive - it thrives. The tools got smarter. The composition stayed simple. The pipe still carries everything."

Call to Action

  1. Today: git diff | copilot -p "review this" -s
  2. This week: Create one .copilot.md file for a daily task
  3. This month: Build a pipeline that saves your team hours

Resources

  • GitHub Copilot CLI: Built into gh
  • markdown-agent: github.com/johnlindquist/agents
  • This outline: [gist link]

Final Slide

Slide: The McIlroy quote from 1978, but the last line reads:

"Write programs to handle text streams, because that is a universal interface."

"...including intelligence."


TIMING SUMMARY

Section Duration Cumulative
Hook: "Let me show you something" 1-2 min 2 min
1978: Doug McIlroy's Prophecy 2-3 min 5 min
Evolution: 50 Years of Pipes 2 min 7 min
Copilot CLI: Non-Interactive Mode 2 min 9 min
Copilot CLI: Piping (The Star!) 3-4 min 13 min
Copilot CLI: Model Escalation 2 min 15 min
Copilot CLI: Permissions 2 min 17 min
The Problem 1 min 18 min
Resolution: markdown-agent 3 min 21 min
Closing 1 min 22 min

Target: 18-20 minutes (buffer for demos and reactions)


KEY QUOTES (For Slides)

"Write programs that do one thing and do it well. Write programs to work together. Write programs to handle text streams, because that is a universal interface." -- Doug McIlroy, 1978

"Same operator. Same philosophy. Fifty years of evolution, and the pipe is still the answer."

"McIlroy's text streams became AI pipelines. grep filters text. Copilot filters meaning."

"The tools got smarter. The composition stayed simple. The pipe still carries everything."


DEMO CHECKLIST

  • Terminal with large font (24pt minimum)
  • Git repo with uncommitted changes for git diff demos
  • Verify copilot CLI is installed and authenticated
  • Pre-written .copilot.md files ready
  • Test all pipelines before talk
  • Backup screenshots/videos of each demo
  • Doug McIlroy photo sourced and credited

COPILOT CLI QUICK REFERENCE

# Non-interactive mode
copilot -p "prompt here"

# Model selection
copilot -p "prompt" --model claude-haiku-4.5
copilot -p "prompt" --model claude-sonnet-4
copilot -p "prompt" --model claude-opus-4.5

# Permission scoping
copilot -p "prompt" --allow-tool 'shell(git:*)'
copilot -p "prompt" --allow-tool Read
copilot -p "prompt" --allow-all-tools

# Piping data in
git diff | copilot -p "review this"
cat error.log | copilot -p "explain this"

BACKUP TALKING POINTS

  • If asked about latency: "Haiku responds in under a second. For pipelines, start with haiku and escalate."
  • If asked about cost: "Haiku is 10x cheaper than Opus. The escalation pattern keeps costs predictable."
  • If asked about security: "Same as any CLI tool - don't pipe secrets, use permission boundaries, audit your workflows."
  • If asked about alternatives: "The markdown format is CLI-agnostic. Change command: copilot to command: claude in one line."

Talk outline for Microsoft AI Dev Days Theme: Piping Hot Intelligence - From Unix History to AI Pipelines Duration: 15-20 minutes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment