Coder Social home page Coder Social logo

omcandido / orla Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 0.0 19.12 MB

ORLA is a symbolic reinforcement learning approach that learns a value-based argumentation framework as a reasoning engine for solving a task. This repo demonstrates ORLA on both the Foggy Frozen Lake and the Takeaway tasks.

Python 11.34% Jupyter Notebook 88.66%
argumentation explainable-ai symbolic-reinforcement-learning keepaway deep-reinforcement-learning frozen-lake reinforcement-learning orla

orla's Introduction

ORLA: Online Reinforcement Learning Argumentation

ORLA is a symbolic RL approach that uses arguments provided by an expert as rules and learns which rules prevail over others via RL. Ultimately, ORLA learns a ranking over the arguments, which can be transformed into a standard value-based argumentation framework (VAF).

Original paper and citation

ORLA: Learning Explainable Argumentation Models

@inproceedings{KR2023-53,
    title     = {{ORLA: Learning Explainable Argumentation Models}},
    author    = {Otero, Cándido and Craandijk, Dennis and Bex, Floris},
    booktitle = {{Proceedings of the 20th International Conference on Principles of Knowledge Representation and Reasoning}},
    pages     = {542--551},
    year      = {2023},
    month     = {8},
    doi       = {10.24963/kr.2023/53},
    url       = {https://doi.org/10.24963/kr.2023/53},
  }

Getting started

To adapt ORLA to your reinforcement learning (RL) task, you will need to do two things:

  1. Create an expert argumentation framework (AF) for your task.
  2. Extend the Environment class, where you will have to implement (at least) the methods:
    • get_premises: from the current observation and memory, which premises hold?
    • get_arguments: from the current premises, which arguments are applicable?
    • update_memory: how should memory be updated at each step?
    • reset_memory: how should memory be initialised?

These methods are the canonical way in which a value-based AF (VAF) is derived from the AF and used as an inference engine for your task.

We provide two implementation examples:

  • Foggy Frozen Lake (FFL): a variant of the classic Frozen Lake game. The FFL notebook introduces ORLA, the FFL game, how the AF is built, how an Environment class is created and showcases ORLA by putting all the pieces together and solving the FFL game. This is the recommended example to start with. FFL was used to test the predecessor of ORLA (more info on my master's thesis Explainable Online Reinforcement Learning Using Abstract Argumentation).

  • Takeaway: a soccer-like game where takers must gain possession of the ball and keepers must prevent it. The takeaway notebook explains the game, the AF and how ORLA is trained. Note that this example does not follow the canonical way to create an Environment, since all the inference is done inside the soccer simulator (via keepaway_orla).

Results

The final results for Takeaway (shown in the paper) can be found in the analysis notebook.

Playing Takeaway with ORLA

Takeaway is implemented using the RoboCup Soccer Simulator (rcssserver) as the world and the keepaway library as an interface between the simulator and the learning agent. To connect ORLA with RoboCup, it is necessary to install rcssserver_orla and keepaway_orla. These two repositories contain all the adjustments needed for ORLA to interact with RoboCup and play Takeaway.

orla's People

Contributors

omcandido avatar

Stargazers

 avatar

Watchers

 avatar  avatar

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.