# Advanced BCI

In this section, you will find some advanced BCI features. Please read the section [BCI](https://emotiv.gitbook.io/cortex-api/bci) first.

The methods in this section are to read and modify the attributes of a training profile. Changing these attributes affects the way the facial expression and mental command detections work. It can make an action easier to detect, or it can completely disable an action.

{% hint style="info" %}
You can use [EmotivBCI](https://www.emotiv.com/emotiv-bci/) to change the attributes of a profile and see how it affects the detections.
{% endhint %}

## Profile name or session id

Most of the methods takes 2 optional parameters, a profile name and a session id.

| Name    | Type     | Required | Description                                                                                           |
| ------- | -------- | -------- | ----------------------------------------------------------------------------------------------------- |
| profile | `string` | no       | The name of a profile.                                                                                |
| session | `string` | no       | A session id returned by [createSession](https://emotiv.gitbook.io/cortex-api/session/createsession). |

You must set one of these 2 parameters, and omit the second parameter.

If you set the **profile**, then Cortex will read the attributes of a profile from the hard drive. You can only read the attributes, you cannot change them. The profile is read only.

If you set the **session**, then Cortex will read the attributes of a profile currently loaded in-memory. You can also change these attributes. The profile is in read-write mode. After you edited the attributes, you should [save the profile](https://emotiv.gitbook.io/cortex-api/bci/setupprofile) to persist your changes.

{% hint style="info" %}
If Cortex tells you that **profile** is a required parameter, then please set this parameter to an empty string.
{% endhint %}

There is a bug in Cortex 2.0.0. The parameter **profile** is required, even if you set the parameter **session**. So, to read/write attributes from a session, you should set the **session** to your session id and set **profile** to an empty string. Don't set it to null, don't omit it.\
This bug is fixed in Cortex version 2.1.0 and above.
