Workshop: Local AI
Getting started guide for using local language models.
Article last updated on 23 April 2026
Four pillars for prompt engineering in patent practice
Every task in this course relies on four methods that anchor quality. With agentic tools like OpenCode or Claude Code, Context Engineering runs automatically; in manual prompting you have to maintain it yourself.
- Context Engineering: a fresh chat for every task, with only the documents relevant to it.
- Duty of evidence: every statement backed by a verbatim quote with reference.
- Paragraph-by-paragraph search: systematically through the whole source.
- Self-reflection + devil's advocate: verify at the end that nothing was missed, take the opposite side.
Start here: your first local model in 30 minutes
Local AI is the prerequisite for confidential work. The setup is worth it once you want to work on confidential documents (drafting, invention disclosure, internal strategy papers).
What to have ready
- A machine with at least 8 GB of RAM for 4B models (Qwen 3, Gemma 3n), 16 GB for Gemma 3 12B, or 32 GB for Gemma 4 27B
- Administrator rights to install software
- A test document (a claim, a short text) for the first conversation
Your path through the course (3 clicks)
- 10 min install: pick an inference framework from the list below. For beginners I recommend LM Studio or Msty (graphical UI). Download and install.
- 10 min model: download a language model. With 16 GB RAM: Gemma 3 12B. With 32 GB RAM: Gemma 4 27B. The first download takes a few minutes.
- 10 min first conversation: in the LM Studio / Msty chat, or with Ollama on the command line, send a first prompt: "Explain in plain language what this patent says: [your test document]." Check the result: slow, but fully local.
When you get stuck
- Hardware not sufficient? Look at the alternatives section: Hugging Face online tests for non-confidential experiments, cloud chatbots for non-confidential documents.
- Installation stuck? The installation videos below walk through Ollama and LM Studio step by step.
- What do I need this for in patent practice? The Patent Drafting course builds directly on it.
- Agent instead of chat? The Agent Framework course explains when OpenCode + Ollama is a step beyond the chat.
Why an inference framework?
Language models like "Llama" or "Gemma" are neural networks stored in special file formats. They cannot be executed directly like other software. An inference framework like Ollama, Msty, or LM Studio handles the work:
- Model loading: Loads the weight files into memory.
- Hardware optimization: Adapts the computations to the available hardware (CPU, GPU, specialized AI chips) and uses optimizations such as quantization to reduce memory consumption.
- API interface: Provides an interface, often compatible with OpenAI standards.
- Memory management: Swaps parts of the model between RAM and disk when necessary.
Install an inference framework
For beginners I recommend Msty or LM Studio; for advanced users, Ollama.
Ollama
FreeLightweight, perfect for automation or use with custom apps. Recommended for advanced users.
DownloadLM Studio
FreeComprehensive, with a user-friendly interface and a ChatGPT-like chat interface. Recommended for beginners.
DownloadMsty
Free for personal useVery user-friendly interface, access to the Ollama model library, RAG ("Ask your data"). Paid for commercial use.
DownloadDownload a language model
The framework alone is just an empty shell. The language model itself has to be downloaded separately. The choice depends on what your hardware can handle and what you intend to use it for.
Qwen 3 (4B)
Compact, Apache 2.0 license. Runs on almost any laptop. Good for first tests and simple tasks.
Gemma 3n (4B)
recommended for laptopLaptop-optimized Gemma 3 variant with selective parameter activation. Low memory footprint, suitable for everyday work on the go.
Gemma 3 (12B)
Mid-range model with a 128K context window. An office action plus the prior art fit into a single prompt. Needs 16 GB RAM or 8 GB VRAM.
Gemma 4 (27B)
recommended for workstationCurrent top-tier option, Apache 2.0 with explicit patent grant. Suitable for local patent drafting. Needs 32 GB RAM or 24 GB VRAM (e.g. RTX 4090).
Installation videos
Two short walkthroughs for the setup:
Installation: Ollama
Installation: LM Studio
Alternatives without local installation
- Hugging Face: The most important platform for open-source models. Many models can be tested directly online. Useful to check whether a local installation is worthwhile before buying hardware. To use this option during the seminar, please create a free account beforehand: huggingface.co.
- Cloud chatbots: For non-confidential data you can also use ChatGPT, Microsoft's Copilot (built on ChatGPT), or Claude.
Further resources
Prompt Library
Create, manage and customize your own prompts.
Patent drafting process
Prompts and notes assigned to the individual process steps.
Cheat sheet: GenAI software
Curated cheat sheet of the GenAI software used in the workshop.
Example invention report (coffee mug)
PDF of a sample invention report. Practice material.
Example invention report (poker chip)
More demanding invention report with two prior-art documents (D1, D2), multiple embodiments and reference numerals — useful to stress-test local models on a realistic drafting case.
Newsletter
Stay up to date on generative AI in patent practice.
Join the GenAI Newsletter