René's URL Explorer Experiment


Title: Live word / character count indicator in the chat composer · Issue #60 · modelstudioai/openwork · GitHub

Open Graph Title: Live word / character count indicator in the chat composer · Issue #60 · modelstudioai/openwork

X Title: Live word / character count indicator in the chat composer · Issue #60 · modelstudioai/openwork

Description: Problem or Motivation OpenWork's chat composer (FreeFormInput) gives no feedback about how much you've written. The composer toolbar already surfaces a context-usage indicator (tokens used / total), a model picker, a thinking-level picke...

Open Graph Description: Problem or Motivation OpenWork's chat composer (FreeFormInput) gives no feedback about how much you've written. The composer toolbar already surfaces a context-usage indicator (tokens used / total)...

X Description: Problem or Motivation OpenWork's chat composer (FreeFormInput) gives no feedback about how much you've written. The composer toolbar already surfaces a context-usage indicator (tokens used ...

Opengraph URL: https://github.com/modelstudioai/openwork/issues/60

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Live word / character count indicator in the chat composer","articleBody":"## Problem or Motivation\n\nOpenWork's chat composer (`FreeFormInput`) gives no feedback about how much\nyou've written. The composer toolbar already surfaces a **context-usage\nindicator** (tokens used / total), a model picker, a thinking-level picker and an\nattach control — but there is **no length feedback for the draft itself**. When\ncomposing a long prompt (a spec, a big paste, a multi-paragraph instruction) you\nhave no glanceable sense of its size.\n\nComparable desktop composers and editors ship exactly this. The **Codex desktop**\ncomposer and editor status bars (VS Code, Google Docs, the Claude/ChatGPT desktop\nmessage boxes) all show a live **word / character count** of what you're\ncurrently typing. It is a small, universally-expected affordance that OpenWork's\notherwise feature-rich composer toolbar is missing.\n\n## Proposed Solution\n\nAdd a small, unobtrusive **draft count indicator** to the composer toolbar\n(left-of-center, next to the attach / working-directory badges, mirroring their\n`!compactMode` rule):\n\n- Shows the **word count** of the current draft inline (e.g. `Words: 12`), only\n  while the composer has non-whitespace text — so the empty composer stays clean.\n- A hover **tooltip** breaks down the full stats: **Words**, **Characters**, and\n  **Lines**.\n- Counts update live on every keystroke (derived from the existing controlled\n  `input` text — no extra state).\n- Hidden in `compactMode` (mirroring the context-usage / thinking / model\n  controls) and hidden entirely when the draft is empty.\n\nThe counting itself (`words` / `characters` / `lines`) lives in a small **pure,\nunit-tested module** so its semantics (Unicode-aware character count,\nwhitespace-collapsing word count, newline-based line count) are locked down\nwithout a DOM.\n\n## Feasibility\n\n**Classification: pure frontend — candidate.** No qwen-code backend involvement.\n\n- The composer already stores the draft as a plain-text string in its controlled\n  `input` state (`FreeFormInput.tsx`); the indicator is pure derived state over\n  that value — no new IPC, no main-process change, no persistence.\n- The indicator reuses the existing composer-toolbar layout (it slots between the\n  left badge group and the flex spacer) and the shared `Tooltip` primitives.\n- Three new i18n keys (`chat.composerWords`, `chat.composerCharacters`,\n  `chat.composerLines`) added to all locales, using a **plural-neutral\n  label form** (`\"Words: {{count}}\"`) so no per-locale plural categories are\n  needed.\n\n## Alternatives Considered\n\n- **Character count only:** simpler, but word count is the more meaningful metric\n  for prose prompts; showing words inline and the full breakdown (words /\n  characters / lines) on hover covers both without clutter.\n- **A live token count of the draft:** more useful in theory but requires a\n  tokenizer that matches the backend model — that is backend-coupled and belongs\n  with the existing context-usage indicator, not a pure-frontend counter.\n- **Always-visible (even when empty):** would clutter the empty composer, which\n  the app deliberately keeps minimal; showing the indicator only when there's\n  content matches the toolbar's other content-dependent affordances.\n\n## Additional Context\n\nFeasibility verified against `apps/electron`: the composer's `input` is a plain\nstring (`coerceInputText`), the `RichTextInput` is a hand-rolled `contentEditable`\nthat fires `onChange` with plain text on every `input` event, and the toolbar's\nbottom row already has a left badge group + flex spacer where the indicator\nslots in cleanly.\n\n### Acceptance criteria (CDP e2e assertion)\n\nA new `e2e/assertions/composer-count.assert.ts` drives the real built app over CDP\nentirely in the draft (no-session) state — no seeded conversation and no backend:\n\n1. The composer's contenteditable renders and, while **empty**, the count\n   indicator (`[data-testid=\"composer-count\"]`) is **absent** — proving it stays\n   hidden for an empty draft.\n2. Real typing (via CDP `Input.insertText` into the focused editor) of\n   `hello world` makes the indicator **appear** with `data-word-count=\"2\"` and\n   `data-char-count=\"11\"` — proving it reflects actual typed content.\n3. Appending more text updates the counts live (word count increases, char count\n   increases) — proving it is reactive per keystroke, not a one-shot render.\n4. Selecting-all and deleting the draft makes the indicator **disappear** again —\n   proving it reacts to the draft becoming empty.\n\nIn addition, the pure counting module ships with unit tests\n(`composer-count.test.ts`) covering empty / whitespace-only input, single vs.\nmultiple words, collapsed internal whitespace, multi-line line counting, and\nUnicode/emoji character counting.\n\nPart of the autonomous desktop-feature loop (`loop-bot`).","author":{"url":"https://github.com/DragonnZhang","@type":"Person","name":"DragonnZhang"},"datePublished":"2026-07-06T01:22:48.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/60/openwork/issues/60"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:294b69cc-df3b-6d0f-eb25-7d71e2c71e76
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idEA58:32982F:119CEC9:17DBB4B:6A521152
html-safe-nonce69d41b7fa8fab461ee6db11cdce7cfe8c556299a10720da164ce69d72f4d950a
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFQTU4OjMyOTgyRjoxMTlDRUM5OjE3REJCNEI6NkE1MjExNTIiLCJ2aXNpdG9yX2lkIjoiNjU3NTEwODc4NDYxMTUyOTA0MiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmaccce2b9de4f25abb0412f5c9224ae636bb777fa4eabced2d76ae72ae16404d774
hovercard-subject-tagissue:4815227718
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/modelstudioai/openwork/60/issue_layout
twitter:imagehttps://opengraph.githubassets.com/0da9834ef6400014aa64aa957401d6732459fb2630dcf9aabf8039e39b79d15f/modelstudioai/openwork/issues/60
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/0da9834ef6400014aa64aa957401d6732459fb2630dcf9aabf8039e39b79d15f/modelstudioai/openwork/issues/60
og:image:altProblem or Motivation OpenWork's chat composer (FreeFormInput) gives no feedback about how much you've written. The composer toolbar already surfaces a context-usage indicator (tokens used / total)...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameDragonnZhang
hostnamegithub.com
expected-hostnamegithub.com
Noneb9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb
turbo-cache-controlno-preview
go-importgithub.com/modelstudioai/openwork git https://github.com/modelstudioai/openwork.git
octolytics-dimension-user_id283556804
octolytics-dimension-user_loginmodelstudioai
octolytics-dimension-repository_id1256697754
octolytics-dimension-repository_nwomodelstudioai/openwork
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id1256697754
octolytics-dimension-repository_network_root_nwomodelstudioai/openwork
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release7aed05249554b889eb33d002851a973eebcc7e91
ui-targetcanary-1
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/modelstudioai/openwork/issues/60#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fmodelstudioai%2Fopenwork%2Fissues%2F60
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fmodelstudioai%2Fopenwork%2Fissues%2F60
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=modelstudioai%2Fopenwork
Reloadhttps://github.com/modelstudioai/openwork/issues/60
Reloadhttps://github.com/modelstudioai/openwork/issues/60
Reloadhttps://github.com/modelstudioai/openwork/issues/60
Please reload this pagehttps://github.com/modelstudioai/openwork/issues/60
modelstudioai https://github.com/modelstudioai
openworkhttps://github.com/modelstudioai/openwork
Notifications https://github.com/login?return_to=%2Fmodelstudioai%2Fopenwork
Fork 3 https://github.com/login?return_to=%2Fmodelstudioai%2Fopenwork
Star 11 https://github.com/login?return_to=%2Fmodelstudioai%2Fopenwork
Code https://github.com/modelstudioai/openwork
Issues 14 https://github.com/modelstudioai/openwork/issues
Pull requests 12 https://github.com/modelstudioai/openwork/pulls
Actions https://github.com/modelstudioai/openwork/actions
Projects https://github.com/modelstudioai/openwork/projects
Security and quality 0 https://github.com/modelstudioai/openwork/security
Insights https://github.com/modelstudioai/openwork/pulse
Code https://github.com/modelstudioai/openwork
Issues https://github.com/modelstudioai/openwork/issues
Pull requests https://github.com/modelstudioai/openwork/pulls
Actions https://github.com/modelstudioai/openwork/actions
Projects https://github.com/modelstudioai/openwork/projects
Security and quality https://github.com/modelstudioai/openwork/security
Insights https://github.com/modelstudioai/openwork/pulse
#61https://github.com/modelstudioai/openwork/pull/61
Live word / character count indicator in the chat composerhttps://github.com/modelstudioai/openwork/issues/60#top
#61https://github.com/modelstudioai/openwork/pull/61
enhancementNew feature or requesthttps://github.com/modelstudioai/openwork/issues?q=state%3Aopen%20label%3A%22enhancement%22
loop-bothttps://github.com/modelstudioai/openwork/issues?q=state%3Aopen%20label%3A%22loop-bot%22
https://github.com/DragonnZhang
DragonnZhanghttps://github.com/DragonnZhang
on Jul 6, 2026https://github.com/modelstudioai/openwork/issues/60#issue-4815227718
enhancementNew feature or requesthttps://github.com/modelstudioai/openwork/issues?q=state%3Aopen%20label%3A%22enhancement%22
loop-bothttps://github.com/modelstudioai/openwork/issues?q=state%3Aopen%20label%3A%22loop-bot%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.