# How to Use AI for Rust Development: Lessons From an OpenAI Engineer

DevFeed: [How to Use AI for Rust Development: Lessons From an OpenAI Engineer](<https://devfeed.tech/articles/how-to-use-ai-for-rust-development-lessons-from-an-openai-engineer-117596.md>)

Original publisher: [Read original article](<https://blog.jetbrains.com/rust/2026/11/04/ai-for-rust-development/>)

Author: Irina Mihajlovic

Published: 2026-11-04T17:09:33Z

Content type: tutorial

Language: en

Sources: [JetBrains](<https://devfeed.tech/sources/the-jetbrains-blog.md>)

Topics: [AI-assisted coding](<https://devfeed.tech/topics/ai-assisted-coding.md>), [Rust](<https://devfeed.tech/topics/rust.md>), [Test automation](<https://devfeed.tech/topics/test-automation.md>), [Memory Safety](<https://devfeed.tech/topics/memory-safety.md>), [codex](<https://devfeed.tech/topics/codex.md>)

Tags: [actions](<https://devfeed.tech/tags/actions.md>), [advanced](<https://devfeed.tech/tags/advanced.md>), [agent](<https://devfeed.tech/tags/agent.md>), [agents](<https://devfeed.tech/tags/agents.md>), [agents-md](<https://devfeed.tech/tags/agents-md.md>), [ai](<https://devfeed.tech/tags/ai.md>), [ai-agent](<https://devfeed.tech/tags/ai-agent.md>), [ai-coding](<https://devfeed.tech/tags/ai-coding.md>), [ai-coding-agents](<https://devfeed.tech/tags/ai-coding-agents.md>), [ai-generated-code](<https://devfeed.tech/tags/ai-generated-code.md>), [ai-tools](<https://devfeed.tech/tags/ai-tools.md>), [api](<https://devfeed.tech/tags/api.md>), [attention](<https://devfeed.tech/tags/attention.md>), [ci](<https://devfeed.tech/tags/ci.md>), [code](<https://devfeed.tech/tags/code.md>), [development](<https://devfeed.tech/tags/development.md>), [frontier](<https://devfeed.tech/tags/frontier.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [livestream](<https://devfeed.tech/tags/livestream.md>), [openai](<https://devfeed.tech/tags/openai.md>), [rust](<https://devfeed.tech/tags/rust.md>), [rust-ai](<https://devfeed.tech/tags/rust-ai.md>)

## AI overview

Predrag Gruevski recommends using AI to raise Rust code quality, while matching review effort to the cost of a mistake. Low-risk work such as CI scripts can be delegated and tested; logic relied on by others deserves deeper scrutiny, and unsafe Rust warrants line-by-line review or manual writing. Reliable prompts sketch the design and test structure, state acceptable assumptions, and specify precise requirements. Verification can combine state and transition tests, coverage checks, cargo-mutants, and, for unsafe code, Miri and sanitizers such as ASan; the engineer still reviews safety invariants. When agents make poor choices, identify missing context and update their instructions. For production code, define what evidence would convince a reviewer--such as readable changes, passing tests, and improved benchmarks--and build the workflow to produce it.

## Source excerpt

"Some people use AI to write more code. I use AI to make my code more correct." Predrag Gruevski's pinned post sums up his approach to using AI for Rust development. Predrag works on frontier systems at OpenAI, and he created cargo-semver-checks and Trustfall. In his work, there's very little room for error. Still, he [...]