Git Product home page Git Product logo

taupy's Introduction

taupy

About

taupy is a Python 3 package for the study of dialectical structures. It can represent arguments, debates, positions, and can perform operations on these objects, including measurements of agreement, polarisation, but also degrees of justification. taupy can also be used to build computer models of dialectical structures, which can be used in agent-based debate simulations.

Installation

The recommended installation method is to use pip:

pip install taupy

License

This project is (c) Felix Kopecky, licensed under BSD-3.

taupy's People

Contributors

kopeckyf avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Forkers

shaunabanana

taupy's Issues

Become agnostic regarding solver logic

Solving a formula, which is connected to various rationality criteria, currently is done using a multitude of strategies. However, the classes taupy.Debate, taupy.Argument and taupy.Position do not have attribute to account for the underlying logic. This needs to change now that the approach to run simulation experiments with three-valued formulas appear more and more promising.

Currently available tools in taupy:

  • binary decision diagrams via dd, very good for #SAT of Boolean (two-valued) debates, but relatively slow for checking whether a given formula is SAT (because the decision tree has to be initialised first). Multi-valued diagrams (MDDs) are an abstraction of BDDs that could, in principle, work for three or n-valued Boolean formulas, but no implementation of MDDs in Python is known. BDDs are used in taupy.satisfiability() and taupy.satisfiability_count().
  • the classic DPLL algorithm via sympy, very bad for #SAT, but very good for checking whether any given Boolean formula is SAT. This function is imported from sympy, stored at dpll_satisfiable() in the modules that need it.
  • the optimised z3 heuristics for #SAT (taupy.z3_all_models()), general SAT checks (using the z3.Solver class) and MaxSAT (using the z3.Optimize class). z3 can be used to check partial two-valued positions, but one can also implement other logics in z3, and then z3 could be used for partial positions that suspend! (big step forward, at least theoretically)

It does not seem to be advisable to use z3 for all purposes. Instances of z3 objects can be quite tricky to handle, causing problems with multi-processing (which ideally would be preserved, since this currently seems necessary to enlarge the sentence pool toward 30 or beyond). More research needed here on how to best integrate z3 objects!

Todo list:

  • Abstraction in Debate, Argument, Position and Simulation classes to account for different logics
  • A new KleeneanSolver class to handle formulas and models from Kleenean logic (I think I have settled for Kleene in favour of ล3, but it shouldn't be too difficult to implement ล3 as well.)

Overhaul polarisation measures to work on adjacency matrices

The group-based polarisation measures currently run on networkx Graph objects. When moving to python-igraph and scikit-learn, group-based polarisation measures should be calculated using numpy matrices only. This will be much faster and will provide a common framework for algorithms from igraph and scikit.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.