logica icon indicating copy to clipboard operation
logica copied to clipboard

Logica AI Intelligence Support

Open yilinxia opened this issue 7 months ago • 1 comments

Currently, Logica embeds OpenAI as the default backend for AI-powered inference within rules — a move toward the NeuroSymbolic paradigm.

Example below

Species(name: "lion");
Species(name: "tiger");
Species(name: "crocodile");
Species(name: "eagle");
Species(name: "shark");

AskAboutSpecies(species1, species2) = """
Just answer true or false.
Do species1 and species2 belong to the same biological category? 
Examples of categories include mammal, reptile, bird, fish.
species1: """ ++ species1 ++ """
species2: """ ++ species2;

@Ground(Species_Rel);
Species_Rel(s1: name1, s2: name2, same_category: result) :-
  result = Intelligence(AskAboutSpecies(name1, name2)),
  Species(name: name1), Species(name: name2), name1 != name2;

We need enable support for alternative AI backends, such as:

  • Google Gemini
  • Local LLMs via API (e.g., llama)

yilinxia avatar May 10 '25 03:05 yilinxia

Gemini support added by Yilin. Local support is yet to arrive.

EvgSkv avatar May 20 '25 23:05 EvgSkv