How to Use An Leabharlann Ghealach

Welcome to An Leabharlann Ghealach, a database for Irish and Celtic source texts. This website will allow users to log and cite texts, keep track of secondary analyses, and discover new texts in the network. An Leabharlann will help keep track of all editions and translations of a text and where they can be found online.

Directory

1. A Graph Database

Neo4j is a graph database language designed to store data as nodes, and connections between data as relationships. Unlike traditional databases that use tables, Neo4j organizes data into a graph structure, making it ideal for representing complex relationships, such as those between authors, texts, editions, publishers, websites, and text versions in this application.

A node has properties, and a relationship connects nodes. For example, if we had a node for Homer, it would look like this:

graph LR H(("Author
name: Homer
born: 8th c. BC")):::entity classDef entity fill:#f9f9f9,stroke:#333,stroke-width:1px;

And if we had a node for the Iliad, it could look like this:

graph LR I(("Text
title: The Iliad
language: Ancient Greek")):::entity classDef entity fill:#f9f9f9,stroke:#333,stroke-width:1px;

Then we could relate them by saying that Homer WROTE The Iliad:

graph LR %% Define two circular nodes with multi-line labels H(("Author
name: Homer
born: 8th c. BC")):::entity I(("Text
title: The Iliad
language: Ancient Greek")):::entity %% Connect them with a labeled arrow H -->|WROTE| I %% Style all .entity nodes classDef entity fill:#f9f9f9,stroke:#333,stroke-width:1px;

You can see that each node is given a label, here "Author" and "Text". The name of the author and title of the text are properties stored within a node. All nodes have labels telling you what they are, while the properties of a node tell you about the data stored within. So Homer IS AN Author, and the Iliad IS A Text. This feature will become useful later when we discuss searching through the database. Note that a node can have an arbitrary number of labels, e.g. James Clarence Mangan IS AN Author and IS A Translator.

2. How is This Database Laid Out?

Due to the complexity of relationships in the humanities, no rigid structure could ever capture the unruly relationships of a humanities database without itself becoming unruly. But Neo4j allows users to set relationships that could be unique, as well as relationships that are extremely common. To capture all of these, users can create many different labels to suit their needs.

A node consists of a label and a list of properties and their values.

Node Labels: Properties:
  • Relationships:
  • Constraints: The database enforces a uniqueness or existence constraint in certain vital node properties. For example, every node must have a unique 'nodeId' property to ensure each node has a valid identifier, and all Author nodes must have a 'name' property, etc...
  • This structure allows a user to create a flexible layout that captures many possible interactions between texts and their authors, publishers, versions, manuscripts, etc., in a way that is navigable and understandable.

    3. Logging In and Registering

    Many features, such as creating, editing, or deleting content, require you to be logged in.

    1. Access the Login Form: Click the "Account" link in the top-right corner of any page.
    2. Log In:
      • Enter your username and password in the login form.
      • Click "Log In". If successful, the "Account" link will show your username with a dropdown to log out.
      • If you encounter an error (e.g., "Invalid credentials"), double-check your username and password.
    3. Register:
      • Click the "Register" link in the login form to go to the registration page.
      • Fill out the form with a unique username and password, then submit.
      • Return to the login form to sign in with your new credentials.
    4. Log Out: Click your username in the top-right corner and select "Log out" from the dropdown.

    4. Exploring the Homepage

    The homepage (index.html) displays lists of nodes organized by labels, such as Authors, Texts, and Editions.

    Use the search bar at the top of any page to find nodes.

    1. Enter a search term (e.g., an author’s name) in the search bar.
    2. Press the "Search" button or hit Enter.
    3. If a matching Author node is found, you’ll be redirected to its details page. Otherwise, an error message like "No results found" will appear.

    6. Viewing Node Details

    The node info page (info.html) displays details about a specific node, such as an Author, Text, or Edition.

    7. Creating a New Node

    Authenticated users can create new nodes (e.g., Authors, Texts) from the homepage.

    1. Log in (see Logging In).
    2. Go to the homepage and find the "+" button next to a column title (e.g., "Authors").
    3. Click the "+" button to go to the create form for that node type.
    4. Fill out the form:
      • Labels: Specify one or more labels (e.g., "Author"). All nodes automatically get the "Entity" label.
      • Properties: Add properties like `name` or `title` (e.g., `name: "Jane Doe"` for an Author).
    5. Submit the form. If successful, you’ll be redirected to the new node’s details page.
    6. Error Handling: If you see an error (e.g., "Invalid label format"), ensure labels and properties use only letters, numbers, or underscores, and avoid reserved names like `nodeId` or `createdBy`.

    8. Editing Node Properties

    Modify a node’s properties from its details page.

    1. Log in and navigate to a node’s details page (e.g., via search or homepage links).
    2. Click the "Edit Properties" button below the node title.
    3. In the form:
      • Edit existing property values (e.g., change `name` from "Jane Doe" to "Jane Smith").
      • Add new properties by clicking "Add Property" and entering a name and value.
      • Delete a property by clicking its "Delete" button in the details table.
    4. Click "Update Properties" to save changes or "Cancel" to discard them.
    5. Error Handling: If you see an error (e.g., "Property names can only contain letters, numbers, underscores"), adjust the property name and try again.

    9. Deleting a Node

    Delete a node and all its relationships from its details page.

    1. Log in and navigate to the node’s details page.
    2. Click the "Delete Node" button (red, next to "Edit Properties").
    3. Confirm the deletion in the pop-up dialog, which warns that all relationships will also be deleted.
    4. If successful, you’ll be redirected to the homepage. If an error occurs (e.g., "You can only delete nodes you created"), you’ll see a message below the form.
    5. Note: Only the node’s creator or an admin can delete it.

    10. Managing Relationships

    Create or delete relationships between nodes on the node details page.

    11. Customizing Homepage Columns

    Adjust the node types displayed on the homepage.

    1. View Default Columns: The homepage shows Authors, Texts, and Editions by default.
    2. Add a Column:
      • Log in to see the "Add Column" dropdown above the columns.
      • Select a label (e.g., "Publisher") from the dropdown and click "Add".
      • A new column will appear with nodes of that label.
    3. Remove a Column:
      • Click the "Remove" button next to a column’s title (not available for default columns unless additional columns are added).
      • The column will disappear, and its label will return to the "Add Column" dropdown.
    4. Note: The homepage always shows at least three columns (Authors, Texts, Editions) to maintain a consistent layout.

    12. Troubleshooting

    Labels

    A list of all labels currently used: