Calligrapher AI
A downloadable Rust project for Windows
(Unofficial) Rust port of the JavaScript web app Calligrapher.ai
See this project's Github page here!
Included are 2 (two) Rust projects.
One is the source to the recurrent neural network library, consisting of over 1000 lines of code with a pre-trained model.
The other is the source to a GUI app that links dynamically to the previously mentioned library.
The library exposes a single function that accepts parameters representing text, handwriting style, legibility, stroke width, & animation speed, along with a callback to handle each new stroke as it's generated in real time in SVG path format.
Output is a filled path (e.g. an outline + fill, not a single line) and only the English alphabet is supported. It is not feasible to retrain the model to support other alphabets at this time.
Support for diacritics is being worked on, but it is uncertain when this will be implemented.
- For instructions on how to use this program via the command line, click this link.
Status | Released |
Category | Tool |
Platforms | Windows |
Author | Girkov Arpa |
Tags | machine-learning, rust, sourcecode |
Purchase
In order to download this Rust project you must purchase it at or above the minimum price of $25 USD. You will get access to the following files:
Development log
- v1.3.0Jul 03, 2023
- v1.2.0Jun 21, 2023
- v1.1.1Jun 04, 2023
- v1.10 Source CodeDec 09, 2022
- v1.1.0Nov 12, 2022
- v1.0.0 (executable)Oct 31, 2022
Comments
Log in with itch.io to leave a comment.
Hi Girkov, I'm a big fan of your work. I just wrote you an email. Can you please get back to me when you can? Best regards Dennis
Thanks for the comment, please check your email.
Hi, I am wondering if this tool can generate large amount of text without becoming smaller. When I tested this on the online app, it didn't really work well. Please let me know. Thanks.
Text can be scaled larger or smaller since version 1.3.0. However, generating only one short paragraph at a time is still recommended.
Hello, do you have an email we can contact you with? I have several questions on wanting to use this for a project I am doing.
Sure, GirkovArpa@protonmail.com
Do you think you could do the same for this? https://github.com/herobd/handwriting_line_generation
Line-break does not work properly.
It starts to put the whole sentence scrambled over several lines.
See Example attached
line-break is set to 2
Thanks for bringing this to my attention, please see the latest version (v1.1.1) which should resolve this issue.
I've tried it now and it works!
Question, To add my own handwriting, is there a way to do this?
(as a new style for example?)
Happy to hear it’s working properly.
It is unfortunately not feasible to add a custom handwriting style at the moment. The model was trained for a long time using expensive hardware, on a massive dataset generated by specific writing equipment in a specific format.
That's what I thougt, but a man can hope right ;)
how do you do line breaks?
seems like the more text you put in the smaller it gets, that's, not super useful... welp another $25 down the drain. Save yourself 25 dollars and just edit the text entry box on the online app. You can remove the character limit and also make the screen bigger to offset the small text when you add a big section.
I’ve asked itch support to refund your purchase.
To enlarge SVGs quickly and easily, this site (not mine) may be helpful.
Hi, when i try to run the source code i get "process didn't exit successfully: `target\debug\calligrapher-ai.exe` (exit code: 101)". Any idea?
Is calligrapher-ai.dll and sciter.dll in the same folder as calligrapher-ai.exe?
Also, calligrapher_ai.dll must be renamed to calligrapher-ai.dll (change the underscore to a dash).
Would be super useful, if there was a WebComponent that get a size and a text attribute and then draws the stuff accordingly in animated form in shadow dom.
Do you mean an export-to-WebComponent option?
Whats the license on this one?
Also the source code seems outdated...
Thanks for bringing that to my attention, the source code has just been updated to include the license and match the pre-compiled release version.
If you have already purchased, please see these instructions here on accessing the updated files.
Hi again, will I have to purchase again?
No, it should be tied to your previous purchase. Please see these instructions here.
Thank you, I see that and it worked.
Just wanted to post an update. I haven’t finished the word-wrap feature, but still working on it.
Thank you for the update. Don´t feel stressed, I have no pressure and am glad you are dedicating yourself to this.
Hey, I’ve uploaded v1.1.0 which supports word-wrap.
It can be a bit slow with longer texts. If this turns out to be a problem, I can look into optimizing it. Just let me know.
Hi, I purchased the script an did the download of sciter sdk. But I have to admit, I do not have a clue, how to use it. Could you give me some direction for that?
Thank you in advance, Stefan
Thank you for your purchase. To compile the project, one would need to install Rust, then type cargo run in a command prompt window in that folder.
If you wish to bypass this step, I’ve uploaded a pre-built executable titled “EXECUTABLE (v1.0.0)”.
This executable maps German characters as described, and has no text-length limit. Text is shrunk to fit.
I am currently working on word-wrap, and hope to complete it within the week.
Regarding a German dataset:
The current model was trained on the English dataset linked here. It is very computationally-intensive; as you can see, even using machine-learning hardware, it took 2 days.
The same source does have a 13th century German dataset, but it’s (presumably) in blackletter, and probably not in the correct format — static images, instead of strokes with velocity data recorded with “eBeam” (a digital whiteboard).
In theory, one could draw text on their computer (preferably using a digital stylus) and convert the strokes to a compatible format for training, but I am not sure how much text would be required. It may be prohibitively time-consuming. Again, there is the issue of computation power necessary to train the model in a reasonable timeframe.
On the bright side, we’re mostly concerned about missing pairs of dots 😁 So I am hopeful I can find a way to figure out where the umlauts are, and add the missing dots on top.
That is great. I am not a programmer and anything like this I have to spend lots of time to understand (if so). Sometimes I have to give up. So your generous help is highly appreciated.
Regards of the dataset, I think, it will not be possible for me, as in the site, for which you sent the link, they talk of several days even on an advanced machine. And lots of contributions of handwritten text.
Perhaps one day any institute will concern to do this tedious (and for me not possible) work.
Well, I am grateful, for what you offer and it is already a lot for me to play with . I am always interested in any forthcoming. Thank you very much again.
Stefan
Hello Girkov, ok I understand. I used so far the Github Version and did not know, that it is different from the Version here. I will purchase. Mapping the mentioned letters would help, even it is only a workaround.
And word wrap would be great. If you would do that for me, great!
What would be necessary for a real German version? Is it difficult to generate a German dataset? Could I do something for that myself?
Thank you for your efforts!
Is it or will it be possible to write longer texts?
I don’t believe there’s any limit on text length, but because word-wrap isn’t implemented, it may go off-screen.
Are you interested in a word-wrap feature?
Hi Girkov, thank you for your answer. I will tell my experiences:
1. The text-box at the bottom takes only 49 letters, when I type there. It is not possible to put more.
2. When I copy text from a text file, I can insert more, than 49 letters, but only 49 are visible. When I click "WRITE" the programm writes without stopping, though the letters after letter 49 are chaotic and without line-wrap. I will have to close the program to use it again.
3. The program does not process special characters as e.g. German Umlaut (ä, ö, ü) or ß. As well as some other as [ or } (what is not so important).
4. A line-wrap also would be great.
Thank you for your attention and kind regards,
Stefan
Unfortunately, this software was trained on an English-language dataset. I do not have access to a compatible German version. If you like, I could patch the app to automatically map ä,ö,ü,ß to ae,oe,ue,ss. But I know that may not be a particularly satisfying solution.
Can I ask if you’re using a copy of the app built from source code purchased here, or simply the prebuilt version from Github? Only the latter should have a ~50 character limit.
Can I use the SVGs in commercial projects?
Of course! There are no restrictions on what you're allowed to do with the output.
Happy handwriting! ✍️