A getting started thing

How do I write an index in a model?

I tried

type Forum struct {
    Title string `dgraph:"title,index" json:"title"`
}
type Forum struct {
    Title string `dgraph:"title,@index(exact,term)" json:"title"`
}