When Kamiah Brown was a freshman at Raoul Wallenberg Traditional High School in San Francisco, she sometimes felt lost and discouraged in the classroom. As one of 21 African American students in her class of 164, there were few faces that looked like hers.

But Brown found mentorship and role models in two African American “success liaisons.” These district staff members, plus a separate nonprofit called SEO Scholars, helped her study for the SAT, polish her college application essay, gather college recommendation letters and apply for summer internships.

It paid off. Brown, 18, is studying public health at George Washington University in Washington, D.C., and credits her success partly to the confidence that grew out of the support at Wallenberg.

“I just feel like without them, I don’t even know what I would do,” Brown said. “Since my freshman year in high school, college was my top priority ... but without them — I really don’t know.”

Brown is an example of a student who benefited from the San Francisco Unified School District’s effort to help more students graduate. According to data released Thursday by the California Department of Education, the district’s graduation rate rose to 89% this year from 87% last year.

This year, 89.5% of African American students earned diplomas, compared with 80.7% in 2018. The graduation rate for Latino students hit 79.9%, up from 76.1% the year before. It jumped to 80.9% for foster youth, up from 64.6% and stood at 89.1% for homeless students, up from 79.9%.

California’s statewide graduation rate is 85.9%.

Officials attribute these higher percentages to a decadelong effort involving a two-fold approach: taking students on tours of colleges and companies to motivate them and increasing communication among teachers, parents and counselors.

Nine high schools — out of the district’s 17 total — added African American Success Liaisons, like those who helped Brown. They coordinate workshops, student-teacher-parent check-ins and counselor meetings. The district has 2,225 African American high school students, according to state data.

“Basically, it’s helping us to make sure the students don’t fall through the cracks,” said SFUSD Superintendent Vincent Matthews.

Matthews said schools take students on field trips to visit the city’s giant tech companies like Google, Twitter and Salesforce, as well as nearby colleges, including UC Berkeley and San Francisco State University. College and the world beyond high school can seem like “Mars” until students see it up close, he said.

“A big part of them graduating is for them to have hope,” Matthews said. “And a big part of having hope is to actually see where they might land.”

District schools adopted programs to ensure students are on track to graduate, Matthews said. If a student is failing a class required for graduation, for example, the teacher will notify a counselor and parent.

More students are prepared for success after high school as well, the data indicate. More than 62% of students were “prepared” for likely success after graduation, according to the data.

However, just 28.4% of African American students said they were prepared.

Brown was raised by her grandparents. One graduated from high school, and the other didn’t. Sometimes, she said, it was difficult for her grandmother to understand that college was more than just a bigger version of high school — it’s about growing as a person, finding herself.

There have been times in her first semester, as she adjusts to a new culture and campus across the country from home, that she feels discouraged.

“But then, I also remembered, people believe in me,” she said.

Anna Bauman is a San Francisco Chronicle staff writer. Email: anna.bauman@sfchronicle.com Twitter: @abauman2