https://github.com/andreasbcs/goal-hiding-dialogues-framework

https://github.com/andreasbcs/goal-hiding-dialogues-framework

Science Score: 13.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (8.9%) to scientific vocabulary
Last synced: 9 months ago · JSON representation

Repository

Basic Info
  • Host: GitHub
  • Owner: AndreasbCS
  • License: gpl-3.0
  • Language: PHP
  • Default Branch: main
  • Size: 305 KB
Statistics
  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Created over 1 year ago · Last pushed over 1 year ago
Metadata Files
Readme License

README.md

Goal-Hiding Dialogues (GHD) Framework

Goal-hiding information-seeking dialogues model interactions where an agent seeks sensitive information by tactically postponing its true goal, opening related topics first to increase the other party’s willingness to discuss sensitive matters. Recognizing goal-hiding strategies is important in various scenarios; e.g., social engineering defense, to detect types of manipulation in online interactions.

This repository manages a PHP implementation of the formal framework of goal-hiding information-seeking dialogues. This code is used in the empirical evaluation presented in the paper "Goal-hiding Information-seeking Dialogues: A Formal Framework" (2024).

Installation

Clone the repository and ensure PHP is installed in your environment.

bash git clone https://github.com/AndreasbCS/goal-hiding-dialogues-framework.git cd goal-hiding-dialogues-framework

Files

  • DialogueManager.php: Tracks and manages dialogue states.
  • QbafManager.php: Implementation of Quantitative Bipolar Argumentation Framework (QBAF). Manages multiple QBAF instances, calculating argument strength changes over time.
  • DependencyGraph.php: Manages the belief-topic dependency graph.
  • evaluation1-dependencyGraph.json: Specifies a particular dependency graph with belief-topic realtions.
  • evaluation1-dialogueScript.json: Specifies a particular dialogue script with topics and belief mappings for dialogue sequences.
  • evaluation1-QBAF.json: Specifies a particular QBAF structure.
  • DialogueProcess.php: Initialization file.

Initialization

DialogueProcess.php initializes the dialogue reasoning process, using predefined parameters and JSON-encoded knowledge bases.

Parameters to Set

  • Discount Factor ($discount): Determines the decay rate of influence of topic strength. Default: php $discount = 0.2;
  • Sensitivity Interval ($sensitivityInterval): Sets a range for topic strength within which topics are considered valid to open. Default: php $sensitivityInterval = array( 'lowerBound' => 0.5, 'upperBound' => 0.7 );
  • Set up knowledge bases php $dependencyGraph_json = file_get_contents("evaluation1-dependencyGraph.json"); $qbaf_json = file_get_contents("evaluation1-QBAF.json"); $dialogueScript_json = file_get_contents("evaluation1-dialogueScript.json");

Input

  • Dialogue History ($input): A string representing the dialogue sequence, where topics (e.g., t0, t1) and beliefs (e.g., b1, b4) alternate as the dialogue progresses. An example: php $input = "t0, b1, t1, b4, t2, b8, t3, b12, t4"; This input is processed to create an array of dialogue moves, where:
    • Each topic (e.g., t0) corresponds to an open_topic move by the seeker.
    • Each belief (e.g., b1) corresponds to an assert_belief move by the respondent.

Breakdown of DialogueProcess.php

  1. Load Knowledge Bases: Load evaluation1-dependencyGraph.json, evaluation1-QBAF.json, and evaluation1-dialogueScript.json.
  2. Convert Dialogue Input: Parse the input string to create a sequence of dialogue moves.
  3. Process Dialogue: After each move, the DialogueManager updates the dialogue state:
    • Open Topic (tX): The seeker initiates a new topic.
    • Assert Belief (bX): The respondent asserts beliefs.
  4. QBAF States: In each dialogue state, the QbafManager adds a new QBAF state, reflecting changes in strengths of topics over dialogue state transitions.
  5. Log Output: The dialogue log presents the QBAFs for each dialogue state, highlighting strengths of each topic changes and newly activated beliefs, relations and topics.

Output

  • QBAFs in Each Dialogue State: After processing the dialogue history, each QBAF state is output in sequence, showing how topic strengths change across dialogue states.
  • Next Suggested Topic: Based on the goal topic and current dialogue state, the framework suggests the next topic to open.

Example Initialization

```php // Load JSON files $dependencyGraphjson = filegetcontents("evaluation1-dependencyGraph.json"); $qbafjson = filegetcontents("evaluation1-QBAF.json"); $dialogueScriptjson = fileget_contents("evaluation1-dialogueScript.json");

// Initialize DependencyGraph, QBAF, and Managers $dependencyGraph = DependencyGraph::graphFromJson($dependencyGraphjson); $qbaf = Qbaf::qbafFromJson($qbafjson); $dialogueLog = new DialogueLog(); $qbafManager = new QbafManager([], $discount, $dialogueLog); $qbafManager->addQbaf($qbaf);

$dialogueManager = new DialogueManager( $topics = $dependencyGraph->getTopics(), $beliefs = $dependencyGraph->getBeliefs(), $qbafManager, $dependencyGraph, $discount, $sensitivityInterval, $dialogueLog );

... ...

$dialogueManager->processDialogue($dialogueHistory, $print);

// Get dialogue after being processed. Beliefs from the input that does not belong to the knowledge base will be removed. $dialogueHistory = $dialogueManager->getDialogue();

// Suggested next move $nextTopic = $dialogueManager->selectTopic($goalTopic);

... ...

```

Authors

  • Andreas Brännström {andreasb@cs.umu.se} Homepage
  • Virginia Dignum {virginia@cs.umu.se} Homepage
  • Juan Carlos Nieves {jcnieves@cs.umu.se} Homepage

Department of Computing Science
Umeå university
SE-901 87, Umeå, Sweden

Owner

  • Name: Andreas Brännström
  • Login: AndreasbCS
  • Kind: user

GitHub Events

Total
  • Delete event: 1
  • Push event: 23
  • Pull request event: 2
  • Create event: 1
Last Year
  • Delete event: 1
  • Push event: 23
  • Pull request event: 2
  • Create event: 1

Issues and Pull Requests

Last synced: over 1 year ago

All Time
  • Total issues: 0
  • Total pull requests: 1
  • Average time to close issues: N/A
  • Average time to close pull requests: 2 minutes
  • Total issue authors: 0
  • Total pull request authors: 1
  • Average comments per issue: 0
  • Average comments per pull request: 0.0
  • Merged pull requests: 1
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 1
  • Average time to close issues: N/A
  • Average time to close pull requests: 2 minutes
  • Issue authors: 0
  • Pull request authors: 1
  • Average comments per issue: 0
  • Average comments per pull request: 0.0
  • Merged pull requests: 1
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
Pull Request Authors
  • AndreasbCS (2)
Top Labels
Issue Labels
Pull Request Labels