Solutions · Text Generation · Text enhancement

One paragraph. Three voices.

The TextRewriter engine reshapes any input into a target communication style while preserving meaning. Three built-in profiles, multilingual support, and streaming events let you give users a "rephrase as professional" or "make this concise" affordance without sending their drafts anywhere.

3 built-in styles Multilingual Streaming events

Concise

Clear, brief, message-first communication.

Professional

Formal register suitable for business and client contexts.

Friendly

Warm, approachable, conversational tone.

Communication styles

Three voices, one engine.

The CommunicationStyle enum offers three calibrated profiles that the engine maps to distinct prompt templates. Each profile is tuned to preserve facts and structure while reshaping tone, register, and pacing.

CommunicationStyle.Concise

Clear and brief. The model strips fillers, redundancies, and qualifying clauses to produce the shortest accurate version. Use for status updates, headlines, and product copy.

CommunicationStyle.Professional

Formal register appropriate for business and client communication. The model normalises contractions, removes slang, and adopts measured phrasing. Use for emails, proposals, and external messaging.

CommunicationStyle.Friendly

Warm and approachable. The model softens directives, adds conversational connectives, and prefers contractions where appropriate. Use for in-app onboarding, support replies, and consumer-facing copy.

Code sample

Same input, three renderings.

RewriteAll.cs
using LMKit.Model;
using LMKit.TextEnhancement;

var model = LM.LoadFromModelID("qwen3.5:4b");
var rewriter = new TextRewriter(model);

string casual = "hey so basically the build's done and ya it works pretty good";

string concise      = rewriter.Rewrite(casual, TextRewriter.CommunicationStyle.Concise);
string professional = rewriter.Rewrite(casual, TextRewriter.CommunicationStyle.Professional);
string friendly     = rewriter.Rewrite(casual, TextRewriter.CommunicationStyle.Friendly);

Console.WriteLine(concise);
// "Build complete. Working as expected."
Console.WriteLine(professional);
// "The build has completed successfully and is functioning as expected."
Console.WriteLine(friendly);
// "Great news! The build is done and working really well."
Applications

Where tone changes everything.

Inbox composer

"Make this professional" / "Make this friendly" buttons in any draft window. Output is generated locally so the email content never touches a third-party service.

Customer support

Rewrite agent replies to match brand voice. Pair with TextCorrection for grammar pass + tone pass before send.

Marketing copy

Draft once, generate three variants for A/B testing. Concise for ads, Professional for white-papers, Friendly for social.

Internal docs

Adapt engineering write-ups for non-technical stakeholders. Friendly variant for status emails, Professional for executive summaries.

Localisation prep

Normalise tone before machine translation. A consistent register source produces more consistent target translations.

In-app onboarding

Generate friendly variants of system messages and microcopy. Improve conversion with warmer phrasing without losing precision.

Developer Resources

API reference.

TextRewriter

Sealed partial class. Construct with an LM, call Rewrite or RewriteAsync with a CommunicationStyle.

View documentation

CommunicationStyle

Enum: Concise, Professional, Friendly. Each value maps to a calibrated prompt template internally.

View documentation

AfterTextCompletion

Streaming event for chunk-by-chunk progress. Subscribe to drive live preview UIs and reactive editors.

View documentation

Demos & docs

Build it. Read it. Try it.

Working console demos on GitHub, step-by-step how-to guides on the docs site, and the API reference for the classes used on this page.

One draft. Every register.

Get Community Edition Download