Inspiration

As a neurodivergent individual I spend a significant amount of time crafting messages in my business and personal life and a good portion of that is around the wording and semantics of the message. The biggest challenge is with communicating with individuals whose communication style is different than mine - a good example of this is with my partner. She and I are both neurodivergent with very complimentary personalities but our communication styles are polar opposites - mine laced with humor and sarcasm while hers is direct and literal.

What it does

Clariform provides the ability to craft messages based on the users and recipients communication style to help remove those "lost in translation" opportunities.

I know there are similar applications, websites and tools that provide similar functionality though as best I can tell most of them let you pick from a preselected target audience - not a specific individual.

How I built it

I started with 2 technical goals:

  • To give myself some broad exposure to directly interacting with LLMs - something I rarely get to do in my day to day.
  • Running language models on the hardware that I own aimed towards identifying what models are viable to run locally and to keep my model costs essentially at zero.

I originally started out with a typescript framework looking at this with an opportunity to get my finger tips into something new, however, I was not happy with the speed of progress knowing that the delivery of this project was measured in days and not weeks or months from when I started.

I made a hard pivot to python, a language which I am familiar with, and was off to the races. The Bolt framework helped improve my initial velocity to receiving my first event from slack and from there I turned my focus to language models.

I spent some time reading some papers regarding communication styles and the signals those styles convey, created a method to convert those signals to personality profiles one may encounter in communication and built a corpus around those profiles.

This built the groundwork for generating and evaluating prompts against a set of language models capable of running on the hardware available - this was several days of iterations with 11 personas, over 20 signal criteria, and eventually some 30 language models evaluated.

Challenges I ran into

The biggest challenge is the limited resources available across the hardware to run the models. I eventually settled on the idea that all of the models should run on a single machine - which did not align well with the models that surfaced during the corpus evaluation.

One model worked well for profile generation and the other worked well for message analysis - there is a third model in the picture that runs on the NPU - but this is used for some routing decisions during direct communication with Clariform.

Despite the significant resources available on the local machine I was not able to get both of these models loaded concurrently - ultimately I deferred to running the model that excelled at message analysis for both. This reduces the model swap thrashing at the expense of profile analysis quality.

In a world where there are no cost limitations - none of these challenges would exist - but there would surely be a significant amount of token spend!

With that said - all of this runs on commodity hardware running in my office at this point - its not capable of running "Internet" scale - but all of the knobs are in place to make the jump to a cloud provider very easily in the future.

One challenge that I am still working through is more so related to the Slack API, SDK and application authorization - there are some nuances related to when a user runs /clariform-revoke that in addition to revoking their token is also revoking the bots token requiring it to be re-installed into the workspace. This very much could be EBKAC its still something I am working on - but that currently waiting in the queue while I write this and work on my video!

Accomplishments that I am proud of

In the end I am happy with what I have achieved in a short time around how to interact with language models through prompt engineering, had a very entertaining time creating the personas, watching how they interact with each other, and the impact an application such as this can have for individuals.

What I learned

I learned a lot in this entire process, however, the one thing that stood out to me was the nuance of the placement of a single comma in a message and how certain personas can perceive that comma.

What's next for clariform

The next steps for Clariform would include:

  • figuring out the issue related to token revocation so I can speak confidently as to the workflows function - and also making sure that one user revoking does not revoke the entire app!
  • Spending some time iterating on the direct message interactions making them feel more conversational than transactional. A good example of this is asking about your profile (at the time I wrote this - maybe its changed when you read this - who knows!) it currently gives you a very matter of fact response which feels very impersonal.
  • Polishing and revising the user experience

Built With

Share this project:

Updates