Skip to content
PrivateAI
← Back to Home
Privacy Workflows

The Developer's Private AI Toolkit: Stop Leaking Code and Prompts to Big Tech

10 min read min readBy PrivateAI Team

Here's the uncomfortable truth: every prompt you paste into ChatGPT, every autocomplete suggestion Copilot generates from your code, and every query you run through a cloud AI assistant is a data point — collected, potentially reviewed, and used to train the next model. For most developers, that means client code, internal architecture decisions, API keys accidentally left in context, and competitive logic are all flowing to servers you don't control.

The good news: a practical, layered private AI stack exists right now. It doesn't require exotic hardware. It takes an afternoon to set up. And it covers 90% of what cloud AI does — without the exposure.

This guide walks through four layers: local inference, private web research, encrypted prompt storage, and secure team collaboration. Use all four for full coverage, or start with the layers that match your biggest risk.


Why Your Current AI Workflow Is a Leak Surface

Before you fix anything, understand what's actually being collected.

OpenAI / ChatGPT: By default, conversation history is used to improve models unless you opt out in Settings → Data Controls. Even with opt-out enabled, conversations may be retained for abuse monitoring. Enterprise plans have stronger guarantees, but most developers use personal accounts.

GitHub Copilot: Code suggestions are generated server-side. GitHub's telemetry documentation confirms that code snippets surrounding your cursor are sent to their servers on every suggestion request — including code in open files, not just what you're typing. Business/Enterprise plans exclude training, individual plans do not.

Claude / Anthropic: Similar story. Free and Pro users' conversations may be used for safety training. Enterprise agreements offer opt-out.

The hidden risk: It's not just the code you paste intentionally. It's the .env file you opened in the same editor session, the internal hostname that appears in a stack trace, the proprietary algorithm structure visible in your surrounding context window.

A local stack doesn't call home. Period.


Layer 1: Local Inference — The Non-Negotiable Foundation

Ollama is the fastest path to running production-quality LLMs on your own hardware. It handles model download, quantization management, and exposes a local OpenAI-compatible API at localhost:11434. No account required. No telemetry by default.

Hardware minimums that actually work:

| RAM | What You Can Run | Use Case |

|-----|-----------------|----------|

| 8 GB | Llama 3.2 3B, Phi-3 Mini | Fast autocomplete, simple Q&A |

| 16 GB | Llama 3.1 8B, Mistral 7B, Gemma 2 9B | Solid coding assistant, document analysis |

| 32 GB | Llama 3.3 70B Q4, Qwen2.5 32B | Near-GPT-4 quality reasoning |

| 64 GB+ | DeepSeek-R1 70B, full Llama 70B | Complex multi-step reasoning |

Getting started:

```bash

Install Ollama

curl -fsSL https://ollama.com/install.sh | sh

Pull a strong coding model

ollama pull qwen2.5-coder:14b

Run it locally

ollama run qwen2.5-coder:14b

```

For IDE integration, Continue.dev (VS Code / JetBrains) connects to your local Ollama endpoint and replaces Copilot with zero telemetry. In ~/.continue/config.json:

```json

{

"models": [

{

"title": "Qwen 2.5 Coder (Local)",

"provider": "ollama",

"model": "qwen2.5-coder:14b"

}

]

}

```

Your keystrokes stay on your machine. Your code never touches a cloud API.

Trade-off to be honest about: Local models at Q4 quantization are slightly behind the frontier models on complex reasoning tasks. For architecting a new distributed system from scratch, you might still reach for Claude or GPT-4. For the daily work — code review, refactoring, documentation, boilerplate — local models are indistinguishable from cloud in practice.


Layer 2: Private Research — When You Actually Need the Web

Local models have a hard cutoff date and no internet access. For research tasks — finding a new library, checking recent CVEs, understanding a framework update — you need web access. The question is which search-AI tool respects your privacy.

Perplexity AI is the most privacy-conscious option in the AI search category that actually delivers useful results. Unlike Google (which has your entire search history, logged-in identity, and location) or ChatGPT Browsing (which ties research to your OpenAI account), Perplexity offers:

  • No account required for basic use — queries aren't tied to a persistent profile
  • Perplexity Pro includes access to Claude and GPT-4 level models for deeper research without the full data profile those companies maintain on you
  • Source citations — you can verify claims rather than trusting a summarization black box
  • Focus modes — Academic, YouTube, Reddit scopes for targeted research without scattering queries across multiple services

Affiliate Disclosure: This article may contain affiliate links. If you make a purchase through these links, we may earn a small commission at no extra cost to you. We only recommend products we genuinely believe in. This helps support our work and allows us to continue providing free content.

For a developer's research workflow, Perplexity is the right compromise: you get real-time web-grounded answers without feeding your research history to a company that's already logged in your browser, tied to your Gmail, and cross-referenced with your Android location data.

Practical rule: Use Ollama for anything involving your actual code or internal context. Use Perplexity for anything that requires current web information. Never paste proprietary code into Perplexity's context.


Layer 3: Encrypted Prompt and Config Storage

Most developers eventually build a library of valuable system prompts: the one that makes code reviews actually useful, the one that generates good test cases, the one tuned for your team's style guide. These prompts represent real intellectual work.

The problem: they usually live in a Notion page, a GitHub repo (sometimes public by accident), or a local file that isn't backed up.

The right solution is end-to-end encrypted cloud storage that syncs across your devices. Proton Drive is the strongest option for individual developers:

  • True E2E encryption — Proton cannot read your files
  • Syncs across Mac, Windows, Linux, iOS, Android
  • Proton's zero-knowledge architecture means even a court order can't produce readable content
  • Part of the Proton ecosystem (Proton Mail, Proton VPN, Proton Pass) if you want a full privacy stack

Affiliate Disclosure: This article may contain affiliate links. If you make a purchase through these links, we may earn a small commission at no extra cost to you. We only recommend products we genuinely believe in. This helps support our work and allows us to continue providing free content.

How to structure your private prompt library:

```

Proton Drive/

└── AI-Workspace/

├── system-prompts/

│ ├── code-review.md

│ ├── architecture-planning.md

│ └── documentation-generator.md

├── ollama-configs/

│ └── modelfiles/

└── project-contexts/

├── client-a-context.md

└── internal-api-context.md

```

The project-contexts/ folder is particularly important: it holds the background context you paste at the start of long sessions. That context often contains internal architecture details, client names, and proprietary business logic — exactly what you don't want in Notion or an unencrypted Dropbox.

Bonus: Proton Drive's desktop app creates a local folder that syncs automatically, so you can reference your prompts from scripts or IDE keybindings without manually downloading files.


Layer 4: Team Collaboration Without Leaking Client Work

If you work with a team or handle client engagements, Layer 3's personal storage isn't enough. You need encrypted sharing with access controls — where you can revoke access, audit who downloaded what, and ensure client deliverables never hit an unencrypted server.

Tresorit is purpose-built for this use case. It's end-to-end encrypted like Proton Drive but adds enterprise-grade collaboration features:

  • Encrypted shared workspaces — team members get E2E encrypted access; Tresorit itself cannot read the files
  • Granular permissions — read-only links for clients, edit access for team, expiring share links
  • Compliance-ready — GDPR, HIPAA, SOC 2 Type II; useful if your clients are in regulated industries
  • Remote wipe — if a team member's device is compromised, you can revoke access and wipe their cached files
  • Full audit log — who accessed what, when, from which IP

Affiliate Disclosure: This article may contain affiliate links. If you make a purchase through these links, we may earn a small commission at no extra cost to you. We only recommend products we genuinely believe in. This helps support our work and allows us to continue providing free content.

How this fits the AI workflow: When your local LLM generates a deliverable — a code audit, architecture document, data analysis — that output often contains client-confidential information. Putting it in Slack (logged), Google Drive (scanned), or regular email (plaintext in transit) is a risk. Tresorit gives you a sharing link that only the intended recipient can open, with the file never stored in plaintext on any server.

For freelancers and consultants, this is also a client expectation management tool: "We handle all deliverables through end-to-end encrypted file sharing" is a meaningful differentiator in an era when clients are increasingly aware of AI data risks.


The Full Workflow, End to End

Here's how the four layers connect in a real working session:

  1. Morning research → Open Perplexity, research without logging in (or with a Pro account separate from your main identity). Find the library, CVE, or framework behavior you need.
  1. Development → Continue.dev (connected to Ollama) handles code completion and inline chat. No code leaves your machine.
  1. Complex reasoning → Pull the relevant system prompt from your Proton Drive folder, paste the local context, run it through Ollama. If the task genuinely requires a frontier model, use Claude or GPT-4 with the minimum context necessary — never paste entire files.
  1. Deliverable handling → Save AI-assisted output to your Tresorit workspace. Share encrypted links with clients or team members rather than email attachments.
  1. Prompt iteration → When you improve a system prompt, update the file in Proton Drive. It syncs to all your devices automatically.

Honest Assessment: Where This Stack Falls Short

This guide would be dishonest if it didn't flag the real gaps.

Quality ceiling: For cutting-edge reasoning tasks — complex mathematical proofs, state-of-the-art code generation for novel architectures, nuanced multi-step planning — frontier models (Claude Opus, GPT-4o) are still ahead of locally-runnable options. The gap is closing fast, but it's real in 2026.

Hardware cost: Running Llama 3.3 70B comfortably requires a machine with 64GB RAM or a dedicated GPU. Apple Silicon M-series chips (M2 Pro and up) are the most accessible path. If you're on a 16GB laptop, you're capped at 8B models.

Setup time: This stack takes an afternoon, not five minutes. Ollama alone is quick; wiring Continue.dev, organizing your Proton Drive structure, and onboarding your team to Tresorit takes real effort.

Network-access gaps: Anything that requires real-time data (stock prices, live API status, current news) needs a web-connected tool. Perplexity fills this role, but it's not zero-knowledge.

The stack is not perfect. It is dramatically better than the default.


Start Here This Week

You don't have to implement all four layers at once. The highest-leverage first step is Ollama + Continue.dev — that alone eliminates the biggest leak surface (code sent to cloud AI) with one afternoon of setup.

Add Proton Drive next to protect your prompt library. Add Tresorit when client collaboration becomes a concern.

The goal is reducing your leak surface to a level that matches the actual sensitivity of your work. For most developers, that means local inference for 80% of tasks, Perplexity for research, and encrypted storage for everything worth protecting.

The cloud AI companies have built excellent products. They've also built excellent data collection pipelines. Choose deliberately which you're willing to feed.


Last updated: 2026-06-29


Want the full private AI setup checklist? We built a one-page reference covering every tool in this stack — model recommendations by hardware tier, Proton Drive folder structure, Tresorit onboarding steps, and Perplexity usage rules. Drop your email below and we'll send it directly (no tracking pixels, plain text).

Get the Private AI Developer Checklist

One-page reference: model tiers, folder structure, and usage rules for the full private stack.