Skip to content

Plugin Examples & Ideas

This page contains complete plugin examples and ideas to inspire your own creations.


Enhance transcriptions using OpenAI GPT models. Fixes grammar, adjusts tone, or summarizes text.

{
"name": "AI Enhance",
"description": "Enhance transcriptions using OpenAI GPT models",
"instructions": "Get your API key from https://platform.openai.com/api-keys",
"hooks": ["before_paste"],
"dependencies": ["openai"],
"author": {
"name": "Freeway Team",
"url": "https://tryfreeway.com",
"email": "[email protected]"
},
"settings": [
{
"type": "text",
"text": "🤖 Powered by OpenAI GPT. Get your key: https://platform.openai.com/api-keys"
},
{
"type": "input",
"name": "api_key",
"label": "OpenAI API Key",
"placeholder": "sk-...",
"required": true,
"help_text": "Your OpenAI API key"
},
{
"type": "select",
"name": "model",
"label": "Model",
"default": "gpt-4o-mini",
"options": [
{"value": "gpt-4o-mini", "label": "GPT-4o Mini (Fast)"},
{"value": "gpt-4o", "label": "GPT-4o (Best)"}
]
},
{
"type": "radio",
"name": "mode",
"label": "Enhancement Mode",
"default": "fix_grammar",
"options": [
{"value": "fix_grammar", "label": "Fix grammar & spelling"},
{"value": "professional", "label": "Make professional"},
{"value": "casual", "label": "Make casual"},
{"value": "summarize", "label": "Summarize"}
]
},
{
"type": "toggle",
"name": "show_status",
"label": "Show processing status",
"default": true
}
]
}
import freeway
def before_paste():
api_key = freeway.get_setting("api_key")
model = freeway.get_setting("model") or "gpt-4o-mini"
mode = freeway.get_setting("mode") or "fix_grammar"
show_status = freeway.get_setting("show_status")
if not api_key:
freeway.log("No API key configured")
return
text = freeway.get_text()
if not text or len(text.strip()) < 3:
freeway.log("Text too short to enhance")
return
if show_status:
freeway.set_status_text("Enhancing with AI 🤖")
freeway.set_indicator_color("#0000FF")
try:
import openai
client = openai.OpenAI(api_key=api_key)
prompts = {
"fix_grammar": "Fix grammar and spelling errors. Only output the corrected text.",
"professional": "Rewrite in a professional tone. Only output the rewritten text.",
"casual": "Rewrite in a casual, friendly tone. Only output the rewritten text.",
"summarize": "Create a concise summary. Only output the summary."
}
response = client.chat.completions.create(
model=model,
messages=[
{"role": "system", "content": prompts.get(mode, prompts["fix_grammar"])},
{"role": "user", "content": text}
]
)
enhanced_text = response.choices[0].message.content.strip()
freeway.set_text(enhanced_text)
freeway.log(f"Enhanced text with {model}")
if show_status:
freeway.set_status_text("✓ Enhanced!")
except Exception as e:
freeway.log(f"Error: {str(e)}")
if show_status:
freeway.set_status_text(f"❌ Error: {str(e)[:30]}")

Toggle hidden files visibility in Finder with a voice command. This example uses a trigger pattern to only activate when the user says “toggle hidden files”.

{
"name": "Toggle Hidden Files",
"description": "Toggle hidden files visibility in Finder with voice command",
"instructions": "Say 'toggle hidden files' to show/hide hidden files in Finder.",
"hooks": ["before_paste"],
"dependencies": [],
"trigger": {
"pattern": "toggle hidden files",
"matchType": "match"
},
"settings": []
}
import freeway
import time
def before_paste():
freeway.log("Toggle hidden files command detected")
# Send Cmd+Shift+. keystroke
freeway.press_keys(["Command", "Shift", "."])
time.sleep(0.2)
freeway.release_keys(["Command", "Shift", "."])
freeway.log("Sent ⌘⇧. keystroke")
freeway.set_status_text("👁 Toggled hidden files")
# Cancel so the trigger phrase isn't pasted
freeway.cancel()

The plugin only runs when the transcribed text exactly matches “toggle hidden files” (case-insensitive). Freeway handles the trigger matching automatically, so the plugin code is much simpler.


Display word and character count without modifying the text.

{
"name": "Word Counter",
"description": "Show word and character count for transcriptions",
"hooks": ["before_paste"],
"dependencies": [],
"settings": []
}
import freeway
def before_paste():
text = freeway.get_text()
if not text:
return
words = len(text.split())
chars = len(text)
freeway.set_text(f"📊 {words} words, {chars} chars\n{text}")

A more advanced example using regex trigger to handle variations of a command.

{
"name": "Web Search",
"description": "Search the web with voice command",
"instructions": "Say 'search for...' or 'look up...' followed by your query.",
"hooks": ["before_paste"],
"dependencies": [],
"trigger": {
"pattern": "^(search for|search|look up|find)\\s+",
"matchType": "regex"
},
"settings": []
}
import freeway
import subprocess
import re
import urllib.parse
def before_paste():
text = freeway.get_text()
if not text:
return
# Remove the trigger phrase to get the search query
query = re.sub(r'^(search for|search|look up|find)\s+', '', text, flags=re.IGNORECASE).strip()
if query:
# URL-encode the query and open in browser
encoded_query = urllib.parse.quote(query)
url = f"https://www.google.com/search?q={encoded_query}"
subprocess.run(["open", url])
freeway.log(f"Searching for: {query}")
freeway.set_status_text(f"🔍 Searching: {query}")
# Don't paste the command
freeway.cancel()

This plugin uses a regex pattern to match “search for”, “search”, “look up”, or “find” at the beginning of the text, followed by the search query.


Here are more ideas for plugins you could build:

  • Email Formatter — Detect email context and add appropriate greetings/signatures
  • Meeting Notes — Format transcriptions as bullet-pointed meeting notes
  • Task Extractor — Extract action items and create todos in your task app
  • Markdown Formatter — Convert spoken formatting cues to Markdown syntax
  • Citation Helper — Format academic citations based on spoken references
  • Blog Post Formatter — Add headings, subheadings, and formatting for blog posts
  • Code Formatter — Format dictated code with proper indentation
  • Git Commit Message — Format transcriptions as conventional commit messages
  • Documentation Generator — Turn spoken descriptions into doc comments
  • Text-to-Speech — Read back the transcription using system TTS
  • Large Text Display — Show transcription in a large overlay window
  • Braille Output — Send text to a Braille display
  • Notion Sync — Append transcriptions to a Notion page
  • Obsidian Notes — Create or append to Obsidian notes
  • Slack Post — Post transcriptions directly to a Slack channel
  • Calendar Event — Create calendar events from spoken details
  • Emoji Enhancer — Add relevant emojis based on sentiment
  • Pirate Speak — Convert text to pirate speak 🏴‍☠️
  • Yoda Translator — Reverse sentence structure, like Yoda speaks

Built something cool? Consider sharing it with the community:

  • Open source it on GitHub
  • Share in Freeway community forums
  • Submit to the Freeway plugin directory (coming soon)