dglazkov / polymath

MIT License
133 stars 9 forks source link

Have a client config #32

Open jkomoros opened 1 year ago

jkomoros commented 1 year ago

When people have a number of server endpoints they like to include.

Instead of having to pass --server https://example.com --server https://foo.com it should be possible to have a config file.

We could have the command by default look for it at a location like config.json but also have an argument to provide a different config.

Some uses for endpoints need there to be a name for them (e.g. wdl, alex etc).

{
  servers: {
    "wdl": "https://polymath.wdl.com",
    "alex": "https://polymath.komoroske.com"
  }
}

Should servers be a dict of id -> url, or id-> object? For example we might want to store alternative names for that server. (You can imagine issuing queries like "Tell me more about ideas that Dimitri has on heroism that differ from Alex's")

In the future we might add other properties to config as a convenient place to stash them.

jkomoros commented 1 year ago