Want to start working on a plugin for Character details and other WorldBuilding Lore

I want to build a plugin for Novel Writing.
Eventually I would want to integrate it with AI using LLM-APIs/local-AI to make a local alternative of SudoWrite or other novel writing websites and only using free local LLM or API prices instead of paying for high subscriptions. And also the ability to modify the plugin to suit your needs will be another advantage you wouldn’t have with paid services.

First, I want options to add features for information about Characters and other World Building stuff like Locations, Religions etc.

Consider for example, the Character information,

  • I would want Name, Alternate/Nick names(Nicknames are Optional. These two are important for AI to detect the names being used in various places and to include the Character info in the context when they are mentioned by the user).
  • Then I would want the option to add various fields related to the Character. (The author would be able to fill in predefined fields set by the plugin and also add new fields and fill them in. They might also choose to create a general purpose field and fill in the details as one would write them instead of using separate fields. The fields can be multiple types like text, one line text, drop down, Tag like etc and whatever else type of fields I’d want to add support in the future.
  • There would be a Research filed which can include any details that won’t be included in the context sent to the AI. Even it will have options for fields.
  • Tags for the Character to filter and group characters.
  • Picture for the Character. Multiple reference images can be added, though only one is in a profile picture format. I think it’s a good idea to have your character as a real or drawn person instead of some faceless character.(The author might hire an artist or use AI to generate them). Images will not be fed to the LLM since AFAIK LLMs only take text as input.
  • Maybe even a Character status sheet for LitRPGs in the future. Not for now.

The use of Name pictures and fields can be use to describe anything in the novel including Characters, Countries, Religions, Lore etc

So, TL;DR, I want to add Name, Aliases, Fields and custom fileds for various details and option to have a profile picture and other pictures for reference.
This makes it easy to create a universal system to describe anything. Since with text and images anything can be described.

I have never coded anything for Obisidian. So, I’m looking on tips for starting on this project. Like how to store this data and how to display it and how to get the data as text when I want it(For LLM AI)
Also, I’m looking for existing projects that have fields etc that I can look at to see how plugins like these work or to build upon them.

I started coding a plugin a view days before.
I think a good approach would be to create a new view-type and file name (this is what i did for my fog of war battlemap plugin)

The file name maybe can be .char and its content should be json. Then in your view you can build the html structure out of the json file. You can even use the json file not only to store data, but also define how the view should look like. That would be a cool plugin, then it could be used for something else too and not only for character definition

users then can create a template and add it to your plugin. And your plugin lets the user choose which template to use for a new .char file

I dont know if you got my idea, but here is a guy who did something you may gave a look at. I didnt check the code, maybe ist garbage, but it should give you an idea

You can look at this too. If it would not create a modal but use a custom view, it may be a thing you can look it too