Below is a sample to get it done:
var note = nlapiCreateRecord('note');
note.setFieldValue('title', 'Some Title');
As of this point in time, 'activity' is not yet documented as part of SuiteScript Records Browser and thus, not considered as officially supported. This code snippet works, but only recommended to use for development and/or testing purposes.
Enhancement# 280389 (SSS/CSS > Support/Document 'activity' field on 'note' record for scripting) is already in place to make it become part of the SuiteScript Records Browser.