open-index/open-npm huggingface dataset:
npm package: @socialgorithm/uabc
Description: Ultimate Algorithm Battle Client
Author: Socialgorithm
Latest version: 10.2.1

# UABC
> uabc: Ultimate Algorithm Battle - Client

This is a websocket client that allows participation in Socialgorithm Tournaments. Learn more about those in our [documentation](https://socialgorithm.org/docs/)

This client will executes your player file, and pipe the stdin/stout generated by that process to the tournament server over a socket.

This means that your player can be written in any language, and it will work as long as your computer can run it.

## Getting started

> Note: If you are participating in a competition, it is best to start in the [Participant section of the documentation](https://socialgorithm.org/docs/sections/participate/).

Install the executable:

```bash
$ npm install -g @socialgorithm/uabc
```
Verify the installation by running:

```bash
$ uabc --version
```

## Options

Run `uabc -h` to see the full list of options:

## Running the sample player

You will need to clone the specific sample player that you want to run, for example, for tic-tac-toe:

```bash
$ git clone git@github.com:socialgorithm/tic-tac-toe-player
$ cd tic-tac-toe-player
```

Then run the sample using the globally installed UABC, for example:

```bash
$ uabc --host "https://sg-tournament.herokuapp.com" 
  --lobby "{YOUR_LOBBY_NAME}" 
  --token "Player1" 
  -f "node run_player.js random"
```
npm package: @socialgorithm/ultimate-ttt
Description: Nodejs implementation of Ultimate Tic Tac Toe
Author: Socialgorithm
Latest version: 10.2.1

# Ultimate Tic Tac Toe - Game Engine
> Ultimate Tic Tac Toe implementation for algorithmic battles & hackathons :)

[![Travis](https://img.shields.io/travis/socialgorithm/ultimate-ttt-js.svg)](https://travis-ci.org/socialgorithm/ultimate-ttt-js)
[![npm](https://img.shields.io/npm/v/ultimate-ttt.svg)](https://www.npmjs.com/package/ultimate-ttt)
[![Coverage Status](https://coveralls.io/repos/github/socialgorithm/ultimate-ttt-js/badge.svg?branch=master)](https://coveralls.io/github/socialgorithm/ultimate-ttt-js?branch=master)
[![npm](https://img.shields.io/npm/dm/ultimate-ttt.svg)](https://www.npmjs.com/package/ultimate-ttt)
[![npm](https://img.shields.io/npm/l/ultimate-ttt.svg)](https://www.npmjs.com/package/ultimate-ttt)

This is a JavaScript implementation of the [Ultimate Tic Tac Toe](https://mathwithbaddrawings.com/2013/06/16/ultimate-tic-tac-toe/) game.

What this package provides is a class that holds all game state and performs all required logic, exposing a simple API.

Example state at a given point:

```js
import UTTT from '@socialgorithm/ultimate-ttt';

const game = new UTTT();

// ... perform some moves ...

console.log(game.prettyPrint());

/*

Outputs the following:

1 - - | - - - | - - -
0 - - | - - - | - - -
1 - - | 1 - - | - - -
------+-------+-------
1 - - | - - - | - - -
- - - | - - - | - - -
- - - | - - - | - - -
------+-------+-------
- 1 - | - - - | - - -
- - - | - - - | - - -
- - - | - - - | - - -
------+-------+-------
*/
```

## Getting started

Install from npm:

```bash
$ npm install --save @socialgorithm/ultimate-ttt
```

Import and use:

```js
import UTTT from '@socialgorithm/ultimate-ttt';
const game = new UTTT();
```

## [API Documentation](https://socialgorithm.org/ultimate-ttt-js/)

## Projects using this

* [**ultimate-ttt-player-js**](https://github.com/socialgorithm/ultimate-ttt-player-js) UTTT Algorithm that plays at random, provided as a base for your own algorithms!
* [**ultimate-ttt/server**](../server/README.md): Game server that uses this package as a game engine to pitch two playing algorithms against each other.