4 min read

Source: Roblox Creator Hub · CC BY 4.0 · View source · Code samples: MIT Imported 2026-10-03. Formatting adapted for this site.

CompletionItemKind

Describes the semantic category of an item returned by the Luau Language Server Protocol (LSP) autocomplete provider. Roblox Studio's script editor uses this value to select the icon shown next to each completion item and to apply autocomplete scoring and filtering logic.

This enum mirrors the LSP CompletionItemKind specification (values 1–25). Plugins that register an autocomplete callback via ScriptEditorService:RegisterAutocompleteCallback() may set the kind field on each CompletionItem to one of these values to hint how their suggestion should be presented.

Items

NameValueDescription
Text1Indicates the completion item represents a plain text suggestion.
Method2Indicates the completion item represents a method on a class or object.
Function3Indicates the completion item represents a function.
Constructor4Indicates the completion item represents a constructor.
Field5Indicates the completion item represents a field within a record or struct.
Variable6Indicates the completion item represents a variable binding.
Class7Indicates the completion item represents a class or type definition.
Interface8Indicates the completion item represents an interface type.
Module9Indicates the completion item represents a module.
Property10Indicates the completion item represents a property on a class or object.
Unit11Indicates the completion item represents a unit of measurement or a module-level value.
Value12Indicates the completion item represents a value expression.
Enum13Indicates the completion item represents an enum type.
Keyword14Indicates the completion item represents a language keyword.
Snippet15Indicates the completion item represents an insertable code snippet with tab stops.
Color16Indicates the completion item represents a color value.
File17Indicates the completion item represents a file reference.
Reference18Indicates the completion item represents a reference to another symbol.
Folder19Indicates the completion item represents a folder or directory.
EnumMember20Indicates the completion item represents an individual enum member value.
Constant21Indicates the completion item represents a constant value.
Struct22Indicates the completion item represents a struct or table type.
Event23Indicates the completion item represents an event.
Operator24Indicates the completion item represents an operator.
TypeParameter25Indicates the completion item represents a generic type parameter.

Text

Indicates the completion item represents a plain text suggestion.

FieldValue
value1

Method

Indicates the completion item represents a method on a class or object.

FieldValue
value2

Function

Indicates the completion item represents a function.

FieldValue
value3

Constructor

Indicates the completion item represents a constructor.

FieldValue
value4

Field

Indicates the completion item represents a field within a record or struct.

FieldValue
value5

Variable

Indicates the completion item represents a variable binding.

FieldValue
value6

Class

Indicates the completion item represents a class or type definition.

FieldValue
value7

Interface

Indicates the completion item represents an interface type.

FieldValue
value8

Module

Indicates the completion item represents a module.

FieldValue
value9

Property

Indicates the completion item represents a property on a class or object.

FieldValue
value10

Unit

Indicates the completion item represents a unit of measurement or a module-level value.

FieldValue
value11

Value

Indicates the completion item represents a value expression.

FieldValue
value12

Enum

Indicates the completion item represents an enum type.

FieldValue
value13

Keyword

Indicates the completion item represents a language keyword.

FieldValue
value14

Snippet

Indicates the completion item represents an insertable code snippet with tab stops.

FieldValue
value15

Color

Indicates the completion item represents a color value.

FieldValue
value16

File

Indicates the completion item represents a file reference.

FieldValue
value17

Reference

Indicates the completion item represents a reference to another symbol.

FieldValue
value18

Folder

Indicates the completion item represents a folder or directory.

FieldValue
value19

EnumMember

Indicates the completion item represents an individual enum member value.

FieldValue
value20

Constant

Indicates the completion item represents a constant value.

FieldValue
value21

Struct

Indicates the completion item represents a struct or table type.

FieldValue
value22

Event

Indicates the completion item represents an event.

FieldValue
value23

Operator

Indicates the completion item represents an operator.

FieldValue
value24

TypeParameter

Indicates the completion item represents a generic type parameter.

FieldValue
value25